We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cd49749 commit 35fe393Copy full SHA for 35fe393
1 file changed
ansible/init-data-gzipper.yaml
@@ -26,9 +26,15 @@
26
dest: "{{ rendered_path }}"
27
mode: "0600"
28
29
+ - name: Check if gzipped file already exists
30
+ ansible.builtin.stat:
31
+ path: "{{ gz_path }}"
32
+ register: gz_file_stat
33
+
34
- name: Gzip the rendered content
35
ansible.builtin.shell: |
36
python3 gzipper.py "{{ rendered_path }}" "{{ gz_path }}"
37
+ when: not gz_file_stat.stat.exists
38
39
- name: Read gzip as base64
40
ansible.builtin.slurp:
@@ -46,4 +52,4 @@
46
52
name: "initdata"
47
53
namespace: "imperative"
48
54
data:
49
- INITDATA: "{{ gz_slurped.content }}"
55
+ INITDATA: "{{ gz_slurped.content }}"
0 commit comments