Skip to content

Commit

Permalink
fixing rm -Rf logic to delete contents of folder but leave parent fol…
Browse files Browse the repository at this point in the history
…der intact
  • Loading branch information
Sarabraj Singh committed May 6, 2022
1 parent 2c350b8 commit df2d303
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion awx/playbooks/project_update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,10 @@
tasks:

- name: delete project directory before update
command: "rm -rf {{project_path}}/*" # volume mounted, cannot delete folder itself
command: "rm -rf {{project_path}}/* {{project_path}}/.* 2>&-" # volume mounted, cannot delete folder itself
tags:
- delete
ignore_errors: true

- block:
- name: update project using git
Expand Down

0 comments on commit df2d303

Please sign in to comment.