aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Berendt <berendt@betacloud-solutions.de>2016-05-26 22:04:25 +0200
committerChristian Berendt <christian@berendt.io>2016-05-27 13:58:31 +0000
commit52d7daadd248be4d527d1a1e1511e27853612543 (patch)
tree14dc4eded58c4cdf763c893a7f9857213a78a9de
parentb40bf517aeb894ed4b79985f66405507e0725ebd (diff)
downloadkolla-52d7daadd248be4d527d1a1e1511e27853612543.tar.gz
kolla-52d7daadd248be4d527d1a1e1511e27853612543.zip
Use file module instead of running rm to remove a directory
This will solve the following issue when running the kolla-ansible cleanup command: [WARNING]: Consider using file module with state=absent rather than running rm Closes-bug: #1586406 Change-Id: I366b6f27e697b24c6c54882c08afe4048803b4e8
-rw-r--r--ansible/roles/cleanup/tasks/cleanup_host.yml4
1 files changed, 3 insertions, 1 deletions
diff --git a/ansible/roles/cleanup/tasks/cleanup_host.yml b/ansible/roles/cleanup/tasks/cleanup_host.yml
index 36a65fb79..266ce1752 100644
--- a/ansible/roles/cleanup/tasks/cleanup_host.yml
+++ b/ansible/roles/cleanup/tasks/cleanup_host.yml
@@ -3,4 +3,6 @@
command: /tmp/kolla-cleanup/tools/cleanup-host
- name: Removing kolla-cleanup folder
- command: rm -rf /tmp/kolla-cleanup
+ file:
+ path: /tmp/kolla-cleanup
+ state: absent