mirror of
https://github.com/borgbase/ansible-role-borgbackup.git
synced 2024-11-19 19:07:42 +01:00
Allow setting borg/borgmatic version (#107)
This commit is contained in:
parent
e1ba1d1364
commit
e34f9311d8
@ -85,6 +85,8 @@ $ git clone https://github.com/borgbase/ansible-role-borgbackup.git roles/ansibl
|
||||
- `borgmatic_store_atime`: Store atime into archive. Defaults to `true`
|
||||
- `borgmatic_store_ctime`: Store ctime into archive. Defaults to `true`
|
||||
- `ssh_key_file`: Path to a private ssh key file (default is `.ssh/id_ed25519`). It generates a ed25519 key if the file doesn't exist yet.
|
||||
- `borg_version`: Force a specific borg version to be installed
|
||||
- `borgmatic_version`: Force a specific borgmatic version to be installed
|
||||
|
||||
|
||||
## Contributing
|
||||
|
@ -35,3 +35,7 @@ borgmatic_cron_minute: "{{ 59 | random(seed=inventory_hostname) }}"
|
||||
borgmatic_cron_checks_day: "{{ range(1, 28) | random(seed=inventory_hostname) }}"
|
||||
borgmatic_cron_checks_hour: "{{ range(9, 24) | random(seed=inventory_hostname) }}"
|
||||
borgmatic_cron_checks_minute: "{{ 59 | random(seed=inventory_hostname) }}"
|
||||
|
||||
|
||||
borg_version: false
|
||||
borgmatic_version: false
|
@ -17,7 +17,7 @@
|
||||
- "{{ ansible_lsb.id }}.yml"
|
||||
|
||||
- name: Run OS-specific tasks
|
||||
include: "{{ item }}"
|
||||
include_tasks: "{{ item }}"
|
||||
with_first_found:
|
||||
- "{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml"
|
||||
- "{{ ansible_os_family }}.yml"
|
||||
@ -44,9 +44,11 @@
|
||||
|
||||
- name: Install main Python Packages
|
||||
pip:
|
||||
name: "{{ borg_python_packages }}"
|
||||
name: "{{ item.name }}"
|
||||
version: "{{ item.version | default(omit, true) }}"
|
||||
virtualenv: /opt/borgmatic
|
||||
when: borg_python_packages is defined
|
||||
loop: "{{ borg_python_packages }}"
|
||||
|
||||
- name: Create borgmatic command in /usr/local/bin
|
||||
copy:
|
||||
|
@ -3,5 +3,7 @@ borg_dependent_python_packages:
|
||||
- cython
|
||||
- pkgconfig
|
||||
borg_python_packages:
|
||||
- borgbackup
|
||||
- borgmatic
|
||||
- name: borgbackup
|
||||
version: "{{ borg_version }}"
|
||||
- name: borgmatic
|
||||
version: "{{ borgmatic_version }}"
|
||||
|
Loading…
Reference in New Issue
Block a user