]> git.phdru.name Git - ansible.git/commitdiff
Feat(ansible/cleanup-tmp): Use args `chdir`; ignore errors with `failed_when`
authorOleg Broytman <phd@phdru.name>
Thu, 31 Oct 2019 19:49:12 +0000 (22:49 +0300)
committerOleg Broytman <phd@phdru.name>
Thu, 31 Oct 2019 19:49:12 +0000 (22:49 +0300)
playbooks/ansible/cleanup-tmp.yml

index eb5bc3771817afffc83b8ee64dc49039be19e462..8d49e6af22fe975fea1eb6169df49a3aa04cde00 100644 (file)
@@ -3,4 +3,7 @@
   gather_facts: false
   tasks:
     - name: Cleanup ~/.ansible/tmp
-      shell: "cd ~/.ansible/tmp && exec rm -rf * || :"
+      shell: "exec rm -rf *"
+      args:
+        chdir: "~/.ansible/tmp"
+      failed_when: false