mirror of
https://github.com/dredx/prole.git
synced 2026-09-27 14:34:30 +00:00
- Installer: Updated k3s deployment logic and configuration generation. - k3s Role: Implemented token drift protection to verify Vault secrets against live node tokens. - DNS: Enhanced samba_reverse_dns role to support multiple reverse zones. - Service Init: Updated initialization scripts and status reporting. - Infrastructure: Added prole management role and k3s diagnostic playbook. - Configuration: Updated prole.cfg and added vaulted group variables.
31 lines
1.1 KiB
YAML
31 lines
1.1 KiB
YAML
---
|
|
- name: Assert Samba DNS admin password is set (vault loaded)
|
|
ansible.builtin.assert:
|
|
that:
|
|
- samba_dns_admin_pass is defined
|
|
- samba_dns_admin_pass | length > 0
|
|
fail_msg: "Missing samba_dns_admin_pass. Create inventory/group_vars/ad_dc.vault.yml with vault_samba_dns_admin_pass."
|
|
|
|
- name: List Samba DNS zones
|
|
ansible.builtin.command:
|
|
cmd: samba-tool dns zonelist {{ samba_dns_server }} -U {{ samba_dns_admin_user }}%{{ samba_dns_admin_pass }}
|
|
register: samba_zones
|
|
changed_when: false
|
|
|
|
- name: Build reverse DNS zone list
|
|
ansible.builtin.set_fact:
|
|
samba_reverse_zones: >-
|
|
{{ ([lan_reverse_zone] + (k3s_reverse_zones | default([]))) | unique }}
|
|
|
|
- name: Create reverse DNS zones if missing
|
|
ansible.builtin.command:
|
|
cmd: samba-tool dns zonecreate {{ samba_dns_server }} {{ reverse_zone }} -U {{ samba_dns_admin_user }}%{{ samba_dns_admin_pass }}
|
|
loop: "{{ samba_reverse_zones }}"
|
|
loop_control:
|
|
loop_var: reverse_zone
|
|
when: reverse_zone not in samba_zones.stdout
|
|
|
|
- name: Ensure minimum PTR records (DC + Pi-holes)
|
|
ansible.builtin.include_tasks: ensure_ptr.yml
|
|
loop: "{{ ptr_records | default([]) }}"
|