Skip to content

Instantly share code, notes, and snippets.

@lordcirth
Created June 12, 2017 21:17
Show Gist options
  • Save lordcirth/e4b57246540771d8da22a9f4b875c2d9 to your computer and use it in GitHub Desktop.
Save lordcirth/e4b57246540771d8da22a9f4b875c2d9 to your computer and use it in GitHub Desktop.
# -*- coding: utf-8 -*-
'''
Management of NFS exports
===============================================
.. code-block:: yaml
To ensure an NFS export exists:
add_export:
nfs_export.present:
- name: '/srv/nfs'
- exports:
- hosts:
- '10.0.2.0/24'
- options:
- 'rw'
This creates the following in /etc/exports:
.. code-block:: bash
/srv/nfs 10.0.2.0/24(rw)
To ensure an NFS export is absent:
delete_export:
nfs_export.absent:
- name: '/srv/nfs'
'''
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment