File tree Expand file tree Collapse file tree 2 files changed +21
-5
lines changed Expand file tree Collapse file tree 2 files changed +21
-5
lines changed Original file line number Diff line number Diff line change 9
9
ansible.builtin.copy :
10
10
dest : target/Corefile
11
11
content : " {{ corefile.resources[0].data.Corefile }}"
12
- - name : Delegate AD Domain To AD
12
+ - name : Delegate AD Domain to AD
13
13
ansible.builtin.lineinfile :
14
14
path : target/Corefile
15
15
search_string : " forward {{ hostvars['sble-addc'].ansible_facts.domain }}. "
21
21
apiVersion : v1
22
22
kind : ConfigMap
23
23
metadata :
24
- namespace : kube-system
25
- name : coredns
24
+ namespace : " {{ corefile.resources[0].metadata.namespace }} "
25
+ name : " {{ corefile.resources[0].metadata.name }} "
26
26
data :
27
27
Corefile : " {{ lookup('file', 'target/Corefile') }}"
28
+ # Some Kubernetes distros (like AKS) prevent you from modifying the Corefile,
29
+ # but provide a separate ConfigMap to edit. So let's provide an override too.
30
+ # modifying the "main" one.
31
+ - name : Update Override Corefile
32
+ kubernetes.core.k8s :
33
+ resource_definition :
34
+ apiVersion : v1
35
+ kind : ConfigMap
36
+ metadata :
37
+ namespace : kube-system
38
+ name : coredns-custom
39
+ data :
40
+ sble-addc.server : |
41
+ {{ hostvars['sble-addc'].ansible_facts.domain }}.:53 {
42
+ errors
43
+ reload
44
+ forward {{ hostvars['sble-addc'].ansible_facts.domain }}. {{ hostvars['sble-addc'].vm_network_ipv4 }}
45
+ }
28
46
29
47
- name : Update Secret-Operator Credentials
30
48
kubernetes.core.k8s :
Original file line number Diff line number Diff line change 68
68
command : get_xml
69
69
uri : " {{ libvirt_uri }}"
70
70
register : created_vm
71
- - debug :
72
- var : created_vm
73
71
# VM can have multiple NICs, extract the one we care about so we can match it against the IP address of the guest later
74
72
- name : Extract VM's MAC address
75
73
community.general.xml :
You can’t perform that action at this time.
0 commit comments