Defined Type: clustershell::group_source

Defined in:
manifests/group_source.pp

Summary

Define group sources

Overview

Examples:

clustershell::group_source { 'slurm':
   ensure  => 'present',
   map     => 'sinfo -h -o "%N" -p $GROUP',
   all     => 'sinfo -h -o "%N"',
   list    => 'sinfo -h -o "%P"',
   reverse => 'sinfo -h -N -o "%P" -n $NODE',
 }

Parameters:

  • map (String)

    map command

  • ensure (Enum['present','absent','file']) (defaults to: 'present')

    Ensure property

  • all (String) (defaults to: 'UNSET')

    all command

  • list (String) (defaults to: 'UNSET')

    list command

  • reverse (String) (defaults to: 'UNSET')

    reverse command

  • section (String) (defaults to: $name)

    Name of section for group source



24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# File 'manifests/group_source.pp', line 24

define clustershell::group_source (
  String $map,
  Enum['present','absent','file'] $ensure = 'present',
  String $all = 'UNSET',
  String $list = 'UNSET',
  String $reverse = 'UNSET',
  String $section = $name,
) {
  include clustershell

  $path = "${clustershell::groups_conf_dir}/${name}.conf"

  file { "clustershell::group_source ${name}":
    ensure  => $ensure,
    path    => $path,
    owner   => 'root',
    group   => 'root',
    mode    => '0644',
    content => template('clustershell/group_source.conf.erb'),
    require => File['/etc/clustershell/groups.conf.d'],
  }
}