Преглед изворни кода

Remove duplicate when statement in Let's Encrypt task

While adding the Let's Encrypt offline testing block in 1746afcc we
accidentially duplicated a the 'when' statement. Ansible only looks at
the last when statement for a given block meaning the earlier one has no
use. This commit merges both lines in one.
Simon Schoeters пре 8 година
родитељ
комит
264c232bbf
1 измењених фајлова са 1 додато и 2 уклоњено
  1. 1
    2
      roles/common/tasks/letsencrypt.yml

+ 1
- 2
roles/common/tasks/letsencrypt.yml Прегледај датотеку

@@ -93,8 +93,7 @@
93 93
   shell: cat /etc/letsencrypt/live/{{ domain }}/cert.pem
94 94
     /etc/letsencrypt/live/{{ domain }}/chain.pem >
95 95
     /etc/letsencrypt/live/{{ domain }}/fullchain.pem
96
-  when: private_key.changed or certificate.changed or ca_certificate.changed
97
-  when: ansible_ssh_user == "vagrant"
96
+  when: (private_key.changed or certificate.changed or ca_certificate.changed) and ansible_ssh_user == "vagrant"
98 97
 
99 98
 - name: Set permissions on combined SSL public cert
100 99
   file: name=/etc/letsencrypt/live/{{ domain }}/fullchain.pem mode=0644

Loading…
Откажи
Сачувај