refs #8142: Package installation moved to the beginning.ç

This commit is contained in:
Xavi Lleó 2025-01-16 11:50:41 +01:00
parent e9c6253812
commit 40c1e21e93
1 changed files with 13 additions and 13 deletions

View File

@ -18,6 +18,12 @@
- name: Gather installed packages
package_facts:
- name: Install adSamba packages
package:
name: "{{ dcsamba_base_packages }}"
# default_release: bookworm-backports # If we want to go 4.21
state: latest
- name: Check if metadata.tdb exists and is not empty
stat:
path: /var/lib/samba/private/sam.ldb.d/metadata.tdb
@ -44,12 +50,7 @@
- when: "not domain_exists"
block:
- name: Install adSamba packages
package:
name: "{{ dcsamba_base_packages }}"
# default_release: bookworm-backports # If we want to go 4.21
state: latest
- name: Add adsamba host to hosts file
blockinfile:
path: /etc/hosts
@ -109,9 +110,13 @@
block:
- name: Extracting variables
no_log: true
#no_log: true
set_fact:
passwords: "{{ lookup(passbolt, 'rndc.key', folder_parent_id=passbolt_folder).password }}"
passwords: "{{ lookup(passbolt, key_name, folder_parent_id=passbolt_folder).password }}"
- name:
debug:
msg: "Las variables son {{ key_name }} -- {{ passwords }} -- {{ key_algorithm }} -- {{ main_dns_server }} -- {{ resolv_domain }} -- {{ name_ad }}.{{ realm }}. -- {{ ip_serverad }}"
- name: Add A record to DNS
nsupdate:
@ -139,8 +144,3 @@
value: '{{ name_ad }}.{{ realm }}.'
state: present
# Hay que crear un registro tipo A con el FQDN es decir el GLUE RECORD en tu DNS. Hecho.
# Luego hay que crear la delegación # update add activedirectory.verdnatura.es. 86400 NS dc1-ad.activedirectory.verdnatura.es. Hecho.
# Bloque de inizialización del dominio ## Hecho.
# Revisar la condicion de domain_join ## Hecho.
# Cuidado con la copia de KRB5, revisar si lo hace ya el samba-tool. ## Hecho.