diff --git a/smartgears/smartgears/tasks/smartgears-app.yml b/smartgears/smartgears/tasks/smartgears-app.yml index f99f3e73..02cb1afc 100644 --- a/smartgears/smartgears/tasks/smartgears-app.yml +++ b/smartgears/smartgears/tasks/smartgears-app.yml @@ -19,7 +19,7 @@ tags: [ 'smartgears', 'smartgears_distribution', 'tomcat'] - name: Remove the smartgears-distribution files - shell: find {{ smartgears_downloads_dir }} -type d -name smartgears-distribution-\* -exec rm -fr {} \; + shell: find {{ smartgears_downloads_dir }} -maxdepth 1 -type d -name smartgears-distribution-* -exec rm -fr {} \; ignore_errors: yes when: ( smartgears_download | changed ) tags: [ 'smartgears', 'smartgears_distribution', 'tomcat']