optimized variable names

This commit is contained in:
2023-11-17 12:35:39 +01:00
parent 6bc6f52f5c
commit dfaa449989
47 changed files with 87 additions and 87 deletions

View File

@@ -1,13 +1,13 @@
- name: "create {{docker_pull_primary_backups_folder}}"
- name: "create {{docker_backup_remote_to_local_folder}}"
file:
path: "{{docker_pull_primary_backups_folder}}"
path: "{{docker_backup_remote_to_local_folder}}"
state: directory
mode: 0755
- name: create backup-remote-to-local.sh
copy:
src: backup-remote-to-local.sh
dest: "{{docker_pull_primary_backups_folder}}backup-remote-to-local.sh"
dest: "{{docker_backup_remote_to_local_folder}}backup-remote-to-local.sh"
mode: 0755
- name: create backup-remote-to-local.service
@@ -16,13 +16,13 @@
- name: create backup-remote-to-local.timer
template: src=backup-remote-to-local.timer.j2 dest=/etc/systemd/system/backup-remote-to-local.timer
register: backup_remote_to_local_timer
changed_when: backup_remote_to_local_timer.changed or activate_all_timers | default(false) | bool
register: backup_backup_remote_to_local_timer
changed_when: backup_backup_remote_to_local_timer.changed or activate_all_timers | default(false) | bool
notify: restart backup-remote-to-local timer
- name: create backup-remote-to-local.sh
template:
src: backup-remote-to-local.sh.j2
dest: "{{docker_pull_primary_backups_folder}}backup-remote-to-local.sh"
dest: "{{docker_backup_remote_to_local_folder}}backup-remote-to-local.sh"
mode: 0755

View File

@@ -4,4 +4,4 @@ OnFailure=systemd-notifier@%n.service cleanup-failed-docker-backups.service
[Service]
Type=oneshot
ExecStart=/usr/bin/bash {{docker_pull_primary_backups_folder}}backup-remote-to-local.sh
ExecStart=/usr/bin/bash {{docker_backup_remote_to_local_folder}}backup-remote-to-local.sh

View File

@@ -3,6 +3,6 @@
hosts="{{pull_remote_backups}}";
errors=0
for host in $hosts; do
bash {{docker_pull_primary_backups_folder}}backup-remote-to-local.sh $host || ((errors+=1));
bash {{docker_backup_remote_to_local_folder}}backup-remote-to-local.sh $host || ((errors+=1));
done;
exit $errors;

View File

@@ -2,7 +2,7 @@
Description=starts pull remote backup timer
[Timer]
OnCalendar={{on_calendar_pull_primary_backups}}
OnCalendar={{on_calendar_backup_remote_to_local}}
RandomizedDelaySec={{randomized_delay_sec}}
Persistent=false

View File

@@ -1 +1 @@
docker_pull_primary_backups_folder: "{{path_administrator_scripts}}pull-primary-backups/"
docker_backup_remote_to_local_folder: "{{path_administrator_scripts}}pull-primary-backups/"