Merge "Properly fail playbook when vault_restore.sh fails"
This commit is contained in:
commit
318456f9be
@ -59,15 +59,7 @@
|
|||||||
shell: >-
|
shell: >-
|
||||||
kubectl exec -n "vault" "{{ vault_manager_pod_name.stdout }}" --
|
kubectl exec -n "vault" "{{ vault_manager_pod_name.stdout }}" --
|
||||||
bash -c "source /opt/script/init.sh; if [ -f $PAUSEFILE ]; then rm -f $PAUSEFILE; fi" 2>&1
|
bash -c "source /opt/script/init.sh; if [ -f $PAUSEFILE ]; then rm -f $PAUSEFILE; fi" 2>&1
|
||||||
rescue:
|
- name: Clean up vault subdir
|
||||||
- name: Clean up vault subdir if in standalone mode
|
|
||||||
file:
|
|
||||||
path: "{{ vault_backup_dir }}"
|
|
||||||
state: absent
|
|
||||||
when: op_mode == "standalone"
|
|
||||||
become: yes
|
|
||||||
|
|
||||||
- name: Cleanup vault subdir
|
|
||||||
file:
|
file:
|
||||||
path: "{{ vault_backup_dir }}"
|
path: "{{ vault_backup_dir }}"
|
||||||
state: absent
|
state: absent
|
||||||
|
Loading…
x
Reference in New Issue
Block a user