2014-03-17 15:55:26 +00:00
|
|
|
---
|
|
|
|
#
|
|
|
|
# This role sets up rsyncd on a server
|
|
|
|
#
|
|
|
|
|
|
|
|
- name: install rsync
|
|
|
|
yum: state=installed name=rsync
|
|
|
|
tags:
|
|
|
|
- packages
|
|
|
|
|
2014-03-17 16:11:23 +00:00
|
|
|
- name: install xinetd
|
|
|
|
yum: state=installed name=xinetd
|
|
|
|
tags:
|
|
|
|
- packages
|
|
|
|
|
2014-03-17 15:55:26 +00:00
|
|
|
- name: rsyncd.conf file
|
|
|
|
copy: src={{ item }} dest=/etc/rsyncd.conf mode=644
|
|
|
|
with_first_found:
|
2014-05-15 03:29:43 +00:00
|
|
|
- "{{ rsyncd_conf }}"
|
2014-03-17 15:55:26 +00:00
|
|
|
- rsyncd.conf.{{ ansible_fqdn }}
|
|
|
|
- rsyncd.conf.{{ host_group }}
|
|
|
|
- rsyncd.conf.default
|
|
|
|
notify:
|
|
|
|
- restart xinetd
|
|
|
|
tags:
|
|
|
|
- config
|
|
|
|
|
|
|
|
- name: xinetd rsync file
|
|
|
|
copy: src={{ item }} dest=/etc/xinetd.d/rsync mode=644
|
|
|
|
with_first_found:
|
|
|
|
- "{{ rsync }}"
|
|
|
|
- rsync.{{ ansible_fqdn }}
|
|
|
|
- rsync.{{ host_group }}
|
|
|
|
- rsync.default
|
|
|
|
notify:
|
|
|
|
- restart xinetd
|
|
|
|
tags:
|
|
|
|
- config
|
|
|
|
|
2014-03-17 16:09:11 +00:00
|
|
|
- name: make sure xinetd is started
|
|
|
|
service: name=xinetd state=started
|
2014-03-17 15:55:26 +00:00
|
|
|
tags:
|
|
|
|
- services
|