-
Notifications
You must be signed in to change notification settings - Fork 0
/
enable-wmco.yaml
37 lines (33 loc) · 1.33 KB
/
enable-wmco.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
- name: create windows machine config operator namespace
kubernetes.core.k8s:
state: present
apply: true
validate_certs: false
resource_definition: "{{ lookup('template', './templates/namespace.yaml.j2') | from_yaml }}"
- name: create the operator group
kubernetes.core.k8s:
state: present
apply: true
validate_certs: false
resource_definition: "{{ lookup('template', './templates/operatorgroup.yaml.j2') | from_yaml }}"
- name: install wmco
kubernetes.core.k8s:
state: present
apply: true
validate_certs: false
resource_definition: "{{ lookup('template', './templates/wmco.yaml.j2') | from_yaml }}"
- name: wait for wmco to be ready
kubernetes.core.k8s_info:
kind: ClusterServiceVersion
api_version: operators.coreos.com/v1alpha1
namespace: "{{ namespace }}"
register: __wmco_operator_install_result
until: "(__wmco_operator_install_result['resources'][0]['status']['phase'] is defined) and (__wmco_operator_install_result['resources'][0]['status']['phase'] == 'Succeeded')"
retries: 15
delay: 15
- name: create secret which will contain the private key that WMCO can use to auth with windows node
kubernetes.core.k8s:
state: present
apply: true
validate_certs: false
resource_definition: "{{ lookup('template', './templates/secret.yaml.j2') | from_yaml }}"