Work around bug in k8s module with the "template" attribute

This commit is contained in:
Shane McDonald
2021-09-29 20:24:00 -04:00
parent 86e0cf884f
commit 8b64670146
5 changed files with 6 additions and 6 deletions

View File

@@ -8,4 +8,4 @@
k8s:
kind: Event
namespace: "{{ ansible_operator_meta.namespace }}"
template: "event.yml.j2"
definition: "{{ lookup('template', 'event.yml.j2') }}"

View File

@@ -49,7 +49,7 @@
- name: Create PVC for backup
k8s:
kind: PersistentVolumeClaim
template: "backup_pvc.yml.j2"
definition: "{{ lookup('template', 'backup_pvc.yml.j2') }}"
- name: Remove PVC ownerReference
k8s:
@@ -68,7 +68,7 @@
name: "{{ ansible_operator_meta.name }}-db-management"
kind: Deployment
state: present
template: "management-pod.yml.j2"
definition: "{{ lookup('template', 'management-pod.yml.j2') }}"
wait: true
- name: Look up details for this deployment

View File

@@ -8,4 +8,4 @@
k8s:
kind: Event
namespace: "{{ ansible_operator_meta.namespace }}"
template: "event.yml.j2"
definition: "{{ lookup('template', 'event.yml.j2') }}"

View File

@@ -76,7 +76,7 @@
name: "{{ ansible_operator_meta.name }}-db-management"
kind: Deployment
state: present
template: "management-pod.yml.j2"
definition: "{{ lookup('template', 'management-pod.yml.j2') }}"
wait: true
- name: Check to make sure backup directory exists on PVC

View File

@@ -60,7 +60,7 @@
namespace: "{{ ansible_operator_meta.namespace }}"
apply: yes
wait: yes
template: "secrets.yml.j2"
definition: "{{ lookup('template', 'secrets.yml.j2') }}"
no_log: true
- name: Remove ownerReference on restored secrets