Cleanup tempdir AFTER it is no longer used

This commit is contained in:
2021-10-02 13:07:29 +02:00
parent 104259a58b
commit b2c827a24f

View File

@@ -386,11 +386,6 @@
dest: "{{ tempdir.path }}/PortfolioPerformance" dest: "{{ tempdir.path }}/PortfolioPerformance"
remote_src: true remote_src: true
- name: clean up temp directory
file:
path: "{{ tempdir.path }}"
state: absent
- name: install portfolio performance - name: install portfolio performance
synchronize: synchronize:
src: "{{ tempdir.path }}/PortfolioPerformance" src: "{{ tempdir.path }}/PortfolioPerformance"
@@ -399,6 +394,11 @@
checksum: true checksum: true
delete: true delete: true
- name: clean up temp directory
file:
path: "{{ tempdir.path }}"
state: absent
when: when:
- not stat_portfolio_performance_installation.stat.exists - not stat_portfolio_performance_installation.stat.exists
- not ansible_check_mode - not ansible_check_mode