Commit 75a4614d authored by Oyvind.Gjesdal's avatar Oyvind.Gjesdal
Browse files

add nfs task file, and default vars

parent 5391019f
Pipeline #42782 passed with stage
in 3 minutes and 12 seconds
......@@ -11,10 +11,13 @@ cron_email: false
cron_users:
- root
- "{{ worker_name | default(omit) }}"
nfs_share_mounts: []
nfs_mount_opts: "defaults,noatime,sec=sys"
nrec_instance: true
centos8_dependencies: ["cronie"]
cron_mailto:
- "oyvind.gjesdal@uib.no"
nfs_version: "4"
ssh_public_keys: []
# - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDdUEJYDOo0cVVs9RPBDr/CFJBCvfVaJw0OX97k92MtYHfMPmIxLwAg5O/Vo4YJiPO8EuHB9sr4YpHEpMq1MnXeJE+kldNk5jz2cabmYNEqVJvlI58qkCGlCcUkGmH5HUIvqUsCV5fQ9Ns5vtAVjmDxRIj6oBFSfZZsazRJN4ZNbSe5TJ4RVI259yz6Vwu+HOBJln4YU14RPPwyKsOq58P/VALZJQ4ptz5PRrXcBwooXEEcIrXKZhgrnxEIaBYidO8jLg2lgRjiAw0pfm7WlMOuH51y4bhioRy5Pe7hA1qkKW04SAPFsOOaTotPSRXYRwYfJpbTwOln4hvF4gHOW1D3"
# - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCutmMDmG4GPzOBbVLe2X8u09TgjYk1udCPZ5TF76fskpwrpRMUmWwcurwCpUgt2bwbDYI/7WioO06rz6xZBkl+4J13ntDxI07nLtiXeGpxzGtoMHsJUB07CluYaCWNvXgrH0Mb1swdqH35pKuwsY+9pmQ84ohe9uZCqqmSJG59yPoBFvU9p7D3ggl+1I4JZhXsK/hnqAY524YvceYIhZPJ7Vg2vEz/o6PpZJtI+5lqWyU97vzoTYyoFiq+C0pCMiWfbU0u8a1ti+Js28AUmT0OOU85EajWqVwOIse69bI2ZdY+AqLTtydYn8b0Js43/k2bJk5dLkbd+U6BMUsiEQNx"
......
......@@ -104,8 +104,14 @@
become: true
when: "hostname is defined and nrec_instance | bool"
- name: "import task nfs"
import_tasks: "nfs.yml"
become: true
when: "nfs_share_mounts | count > 0"
- name: "install extra packages {{ centos7_extra_packages | default ([]) }} if defined"
yum:
name: "{{ centos7_extra_packages }}"
become: true
when: "centos7_extra_packages is defined"
- name: "Install NFS mount utility"
become: true
yum:
name: "nfs-utils"
state: "present"
become: true
- name: Mount NFS share_mounts
become: true
mount:
fstype: nfs
name: "{{ item.path }}"
opts: "vers={{ nfs_version }},{{ item.opts | default(nfs_mount_opts) }}"
src: "{{ item.location }}"
dump: "{{ item.dump | default(omit) }}"
passno: "{{ item.passno | default(omit) }}"
state: "{{ item.state | default( 'mounted' ) }}"
with_items: "{{ nfs_share_mounts }}"
loop: "{{ nfs_share_mounts }}"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment