Solved bugs and removed debug messages if repository is not reachable

This commit is contained in:
2024-01-05 11:08:09 +01:00
parent 5ad6bf7e34
commit d24b0dc839
10 changed files with 3 additions and 67 deletions

View File

@@ -3,15 +3,9 @@
repo: "https://github.com/kevinveenbirkenbach/cleanup-failed-docker-backups.git"
dest: "{{backup_docker_to_local_cleanup_folder}}"
update: yes
register: git_result
ignore_errors: true
when: run_once_cleanup_failed_docker_backups is not defined
- name: Warn if repo is not reachable
debug:
msg: "Warning: Repository is not reachable."
when: git_result is defined and git_result.failed is defined and run_once_cleanup_failed_docker_backups is not defined
- name: configure cleanup-failed-docker-backups.service
template:
src: cleanup-failed-docker-backups.service.j2