prepend all vars with role name

This commit is contained in:
Luc Stroobant 2017-10-01 13:05:59 +02:00
parent 11b3efb8ba
commit 89085c5d17
7 changed files with 23 additions and 21 deletions

View file

@ -11,7 +11,7 @@
lineinfile:
dest: "/root/.borg.passphrase"
state: "present"
line: 'export BORG_PASSPHRASE="{{ borg_passphrase }}"'
line: 'export BORG_PASSPHRASE="{{ borgbackup_passphrase }}"'
create: "yes"
- name: client | template sshconfig for backup-hosts (no strict key checking)

View file

@ -2,11 +2,11 @@
- name: server | install borg backup
get_url:
dest: "/usr/local/bin/borg"
checksum: "{{ borg_checksum }}"
checksum: "{{ borgbackup_checksum }}"
owner: "root"
group: "root"
mode: "0755"
url: "{{ borg_download_url }}"
url: "{{ borgbackup_download_url }}"
delegate_to: "{{ item.fqdn }}"
with_items: "{{ backupservers }}"
when: item.type == 'normal'

View file

@ -2,9 +2,9 @@
- name: install borg backup
get_url:
dest: "/usr/local/bin/borg"
checksum: "{{ borg_checksum }}"
checksum: "{{ borgbackup_checksum }}"
owner: "root"
group: "root"
mode: "0755"
url: "{{ borg_download_url }}"
url: "{{ borgbackup_download_url }}"
tags: borginstall

View file

@ -2,7 +2,7 @@
- include: install.yml
when: >
backup_required == True or
borgbackup_required == True or
inventory_hostname in groups.backupservers or
restore == True
@ -11,10 +11,10 @@
- include: borg-client.yml
when: >
backup_required == True and
borgbackup_required == True and
inventory_hostname not in groups.backupservers
- include: restore.yml
when: >
restore == True and
borgbackup_do_restore == True and
inventory_hostname not in groups.backupservers