2019-10-06 20:55:56 +00:00
|
|
|
---
|
|
|
|
# Server/Borgbackup: Install and Setup Borgbackup Backup Crobjob - Debian Stretch Version
|
|
|
|
# Variables (must be set!):
|
2019-11-12 20:06:04 +00:00
|
|
|
# - borgbackup_passphrase
|
|
|
|
# - borgbackup_repo
|
|
|
|
# - borgbackup_hostname
|
2019-10-06 20:55:56 +00:00
|
|
|
|
|
|
|
# For Debian Stretch, use a newer package version from backports
|
|
|
|
|
2023-04-28 21:25:21 +00:00
|
|
|
- name: Borgbackup - Add debian repo key
|
2022-02-13 19:52:02 +00:00
|
|
|
when:
|
|
|
|
- ansible_distribution_release == 'stretch'
|
2023-04-28 21:25:21 +00:00
|
|
|
become: true
|
2021-08-28 14:50:37 +00:00
|
|
|
ansible.builtin.apt_key:
|
2019-10-06 20:55:56 +00:00
|
|
|
keyserver: pgpkeys.mit.edu
|
|
|
|
id: 8B48AD6246925553
|
|
|
|
state: present
|
2023-04-28 21:25:21 +00:00
|
|
|
- name: Borgbackup - Add stretch-backports
|
2019-10-06 20:55:56 +00:00
|
|
|
when:
|
|
|
|
- ansible_distribution_release == 'stretch'
|
2023-04-28 21:25:21 +00:00
|
|
|
become: true
|
2021-08-28 14:50:37 +00:00
|
|
|
ansible.builtin.apt_repository:
|
2019-10-06 20:55:56 +00:00
|
|
|
repo: deb http://ftp.debian.org/debian stretch-backports main
|
|
|
|
state: present
|
2023-04-28 21:25:21 +00:00
|
|
|
- name: Borgbackup - Install borgbackup from stretch-backports
|
2019-10-06 20:55:56 +00:00
|
|
|
when:
|
2022-02-13 19:52:02 +00:00
|
|
|
- borgbackup_passphrase is defined
|
|
|
|
- borgbackup_repo is defined
|
|
|
|
- borgbackup_hostname is defined
|
2019-10-06 20:55:56 +00:00
|
|
|
- ansible_distribution_release == 'stretch'
|
2023-04-28 21:25:21 +00:00
|
|
|
become: true
|
2021-08-28 14:50:37 +00:00
|
|
|
ansible.builtin.apt:
|
2019-10-06 20:55:56 +00:00
|
|
|
name: borgbackup
|
|
|
|
state: latest
|
|
|
|
default_release: stretch-backports
|
2023-04-28 21:25:21 +00:00
|
|
|
update_cache: true
|
2019-10-06 20:55:56 +00:00
|
|
|
cache_valid_time: 3600
|
2023-04-28 21:25:21 +00:00
|
|
|
diff: false
|