Last active
December 7, 2018 11:45
-
-
Save jserviceorg/48905c3d24fa93469ff5b8c28bfeb32f to your computer and use it in GitHub Desktop.
create rsnapshot hostlist for rsnapshot
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: backup | |
tasks: | |
- name: generate hostlist root backup for rsnapshot | |
lineinfile: "dest=/opt/rsnapshot/rsnapshot.conf | |
line='{{ item }} / {{ item }}/' | |
state=present" | |
with_items: | |
- "{{ groups['all'] }}" | |
- name: generate hostlist root backup for rsnapshot | |
lineinfile: "dest=/opt/rsnapshot/rsnapshot.conf | |
line='{{ item }} /data {{ item }}/data' | |
state=present" | |
with_items: | |
- "{{ groups['all'] }}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment