Try to conditionalize exportfs.

This commit is contained in:
Ralph Bean 2014-10-16 16:36:26 +00:00
parent 2fbf57eb6c
commit b8e942e2d7

View file

@ -11,6 +11,7 @@
copy: src={{ ansible_fqdn }}-exports dest=/etc/exports
tags:
- nfs/server
register: exports
- name: enable nfs-related services and run them (fedora)
action: service name={{ item }} enabled=true state=started
@ -27,3 +28,7 @@
- nfs
- nfslock
when: ansible_distribution == 'RedHat'
- name: Kick exportfs if /etc/exports changed
command: /usr/sbin/exportfs -ra
when: exports.changed