2015-05-28 11:32:57 +02:00
|
|
|
---
|
|
|
|
- name: Install the vsftpd package
|
2017-11-06 21:48:20 +01:00
|
|
|
apt: pkg=vsftpd state=installed update_cache=yes cache_valid_time=3600
|
2016-03-02 19:59:02 +01:00
|
|
|
tags: [ 'vsftpd', 'ftp' ]
|
2015-05-28 11:32:57 +02:00
|
|
|
|
|
|
|
- name: Install the vsftpd configuration file
|
|
|
|
template: src=vsftpd.conf.j2 dest=/etc/vsftpd.conf mode=0444 owner=root group=root
|
|
|
|
notify: Restart the vsftpd server
|
2016-03-02 19:59:02 +01:00
|
|
|
tags: [ 'vsftpd', 'ftp' ]
|
|
|
|
|
|
|
|
- name: Start and enable the vsftpd server
|
|
|
|
service: name=vsftpd state=started enabled=yes
|
|
|
|
when: vsftpd_server_enabled
|
|
|
|
tags: [ 'vsftpd', 'ftp' ]
|
|
|
|
|
|
|
|
- name: Stop and disable the vsftpd server
|
|
|
|
service: name=vsftpd state=stopped
|
|
|
|
when: not vsftpd_server_enabled
|
|
|
|
tags: [ 'vsftpd', 'ftp' ]
|
|
|
|
|
2015-05-28 11:32:57 +02:00
|
|
|
|