prole/infrastructure/roles/samba_dns/tasks/main.yml
chrisfu b8a55888be checkpoint: update GKE deployment docs and infra changes
Summarize CLAUDE.md updates:

- Document both live GKE clusters as e2-standard-2 x3 in us-west3 and note stale app default in code.

- Call out DB cluster naming mismatch between conf (knoe-dev-cnpg-0) and code default (knoe-cnpg-0).

- Add SSD quota guidance: 300GB fully consumed by CNPG, so non-CNPG PVCs must use standard/pd-standard.

- Refresh reset script reference and quota section details to match current runtime state.

Co-authored-by: Junie <junie@jetbrains.com>
2026-04-18 07:18:10 -07:00

27 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: Create forward DNS zone if missing
ansible.builtin.command:
cmd: samba-tool dns zonecreate {{ samba_dns_server }} {{ prole_domain }} -U {{ samba_dns_admin_user }}%{{ samba_dns_admin_pass }}
when: prole_domain not in samba_zones.stdout
- name: Ensure forward A records (internal RFC1918 hosts and k3s front-door)
ansible.builtin.include_tasks: ensure_a.yml
loop: "{{ (prole_internal_a_records | default([])) + (prole_k3s_dns_records | default([])) }}"
- name: Ensure forward CNAME records
ansible.builtin.include_tasks: ensure_cname.yml
loop: "{{ prole_k3s_cname_records | default([]) }}"