Files
awx-operator/roles/restore/tasks/import_vars.yml

21 lines
515 B
YAML

---
- name: Import awx_object variables
block:
- name: Create temp file for spec dict
tempfile:
state: file
register: tmp_spec
- name: Get AWX object definition from pvc
k8s_cp:
namespace: "{{ backup_pvc_namespace }}"
pod: "{{ ansible_operator_meta.name }}-db-management"
remote_path: "{{ backup_dir }}/awx_object"
local_path: "{{ tmp_spec.path }}"
state: from_pod
- name: Include spec vars to save them as a dict
include_vars: "{{ tmp_spec.path }}"