Manage nfs-client configuration file.
This commit is contained in:
parent
413fc20c6a
commit
361a1e0cee
|
@ -11,12 +11,14 @@
|
|||
|
||||
## Overview
|
||||
|
||||
Manage NFS (client) installation.
|
||||
Manage NFS (client) installation and configuration.
|
||||
|
||||
## Role Variables
|
||||
|
||||
* **nfs_cli_manage** : If `nfs-client` should be managed with this role [default : `true`].
|
||||
* **nfs_cli_pkg_state** : State of new `nfs-client` package(s) [default : `installed`].
|
||||
* **nfs_cli_conf_path** : Configuration file for `nfs-client` [default : `/etc/default/nfs-common`].
|
||||
* **nfs_cli_conf_tpl** : Template used to generate the previous config file [default : `etc/default/nfs-common.j2`].
|
||||
|
||||
### OS Specific Variables
|
||||
|
||||
|
@ -38,6 +40,7 @@ Please see default value by Operating System file in [vars][vars directory] dire
|
|||
|
||||
This role will :
|
||||
* Install needed packages to provide `nfs-client`.
|
||||
* Manage `nfs-client` configuration files.
|
||||
|
||||
## Development
|
||||
|
||||
|
|
|
@ -4,3 +4,5 @@
|
|||
# client
|
||||
nfs_cli_manage: true
|
||||
nfs_cli_pkg_state: 'installed'
|
||||
nfs_cli_conf_path: '/etc/default/nfs-common'
|
||||
nfs_cli_conf_tpl: 'etc/default/nfs-common.j2'
|
||||
|
|
|
@ -15,4 +15,16 @@
|
|||
state: '{{ nfs_cli_pkg_state }}'
|
||||
with_items:
|
||||
- '{{ nfs_cli_pkg_list }}'
|
||||
when: nfs_cli_manage
|
||||
|
||||
- name: CONFIG nfs-client
|
||||
template:
|
||||
src: '{{ nfs_cli_conf_tpl }}'
|
||||
dest: '{{ nfs_cli_conf_path }}'
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0644
|
||||
backup: true
|
||||
when: nfs_cli_manage
|
||||
|
||||
# }}}
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
# {{ ansible_managed }}
|
||||
|
||||
# If you do not set values for the NEED_ options, they will be attempted
|
||||
# autodetected; this should be sufficient for most people. Valid alternatives
|
||||
# for the NEED_ options are "yes" and "no".
|
||||
|
||||
# Do you want to start the statd daemon? It is not needed for NFSv4.
|
||||
NEED_STATD=
|
||||
|
||||
# Options for rpc.statd.
|
||||
# Should rpc.statd listen on a specific port? This is especially useful
|
||||
# when you have a port-based firewall. To use a fixed port, set this
|
||||
# this variable to a statd argument like: "--port 4000 --outgoing-port 4001".
|
||||
# For more information, see rpc.statd(8) or http://wiki.debian.org/SecuringNFS
|
||||
STATDOPTS=
|
||||
|
||||
# Do you want to start the idmapd daemon? It is only needed for NFSv4.
|
||||
NEED_IDMAPD=
|
||||
|
||||
# Do you want to start the gssd daemon? It is required for Kerberos mounts.
|
||||
NEED_GSSD=
|
Reference in New Issue