mirror of
https://github.com/geerlingguy/ansible-role-nfs
synced 2025-01-20 19:10:20 +01:00
Issue #1: Make role work on Ubuntu/Debian.
This commit is contained in:
parent
619a751fb3
commit
b71bb51c8d
4 changed files with 31 additions and 10 deletions
|
@ -3,14 +3,19 @@ dependencies: []
|
|||
|
||||
galaxy_info:
|
||||
author: geerlingguy
|
||||
description: NFS installation for RHEL/CentOS.
|
||||
description: NFS installation for Linux.
|
||||
company: "Midwestern Mac, LLC"
|
||||
license: "license (BSD, MIT)"
|
||||
min_ansible_version: 1.4
|
||||
platforms:
|
||||
- name: EL
|
||||
versions:
|
||||
- 6
|
||||
- 7
|
||||
- all
|
||||
- name: Debian
|
||||
versions:
|
||||
- all
|
||||
- name: Ubuntu
|
||||
versions:
|
||||
- all
|
||||
categories:
|
||||
- system
|
||||
|
|
|
@ -1,9 +1,7 @@
|
|||
---
|
||||
- name: Ensure NFS utilities are installed.
|
||||
yum: name=nfs-utils state=installed
|
||||
# Setup/install tasks.
|
||||
- include: setup-RedHat.yml
|
||||
when: ansible_os_family == 'RedHat'
|
||||
|
||||
- name: Ensure rpcbind and nfs are running.
|
||||
service: name={{ item }} state=started enabled=yes
|
||||
with_items:
|
||||
- rpcbind
|
||||
- nfs
|
||||
- include: setup-Debian.yml
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
|
9
tasks/setup-Debian.yml
Normal file
9
tasks/setup-Debian.yml
Normal file
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
- name: Ensure NFS utilities are installed.
|
||||
apt: "name={{ item }} state=installed"
|
||||
with_items:
|
||||
- nfs-common
|
||||
- nfs-kernel-server
|
||||
|
||||
- name: Ensure NFS is running.
|
||||
service: name=nfs-kernel-server state=started enabled=yes
|
9
tasks/setup-RedHat.yml
Normal file
9
tasks/setup-RedHat.yml
Normal file
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
- name: Ensure NFS utilities are installed.
|
||||
yum: name=nfs-utils state=installed
|
||||
|
||||
- name: Ensure rpcbind and nfs are running.
|
||||
service: "name={{ item }} state=started enabled=yes"
|
||||
with_items:
|
||||
- rpcbind
|
||||
- nfs
|
Loading…
Reference in a new issue