retrace: Fix faf db backup job
The job was broken before because the backup directory (`/srv/faf/db-backup`) might not have existed. Also, factor out some magic values into variables.
This commit is contained in:
parent
2ce5a4b91b
commit
6b57d23220
2 changed files with 15 additions and 0 deletions
|
@ -4,3 +4,9 @@ archive_age: '+14'
|
|||
|
||||
# Delete deferred reports
|
||||
deferred_age: '+7'
|
||||
|
||||
# Directory for saving FAF database backups.
|
||||
faf_backup_dir: /srv/faf/db-backup
|
||||
|
||||
# Delete FAF database backups older than this period.
|
||||
faf_old_backup_age: '+7'
|
||||
|
|
|
@ -16,6 +16,15 @@
|
|||
tags: add_repo
|
||||
loop: "{{ faf_repos }}"
|
||||
|
||||
- name: Ensure directory for FAF database backups exists
|
||||
file:
|
||||
path: "{{ faf_backup_dir }}"
|
||||
state: directory
|
||||
owner: faf
|
||||
group: faf
|
||||
mode: 0750
|
||||
when: env != 'staging'
|
||||
|
||||
- import_tasks: cron.yml
|
||||
tags: cron
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue