Merge pull request #827 from mslacken/gendersTemplate
added genders examples
This commit is contained in:
@@ -66,6 +66,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
- Check for formal correct IP and MAC addresses for command line options and
|
||||
when reading in the configurations
|
||||
- Added template to create genders database
|
||||
- Write log messages to stderr rather than stdout. #768
|
||||
- Updates to Makefile for clarity, notably removing genconfig and replacing
|
||||
test-it with test. #890
|
||||
@@ -93,8 +94,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
format and create the file systems on the disks. For every a file system a systemd mount unit
|
||||
file is create and will executed after the `ignition-disks-ww4.service` has finished.
|
||||
Entries in `/etc/fstab` for every file system are created with the `noauto` option.
|
||||
|
||||
- wwclient has now a commandline switch for the location of warewulf.conf
|
||||
|
||||
## [4.4.0] 2023-01-18
|
||||
|
||||
### Added
|
||||
|
||||
10
etc/examples/genders.ww
Executable file
10
etc/examples/genders.ww
Executable file
@@ -0,0 +1,10 @@
|
||||
# This file is autogenerated by warewulf
|
||||
# Host: {{.BuildHost}}
|
||||
# Time: {{.BuildTime}}
|
||||
# Source: {{.BuildSource}}
|
||||
{{- range $node := $.AllNodes}} {{/* for each node */}}
|
||||
{{ $node.Id.Get }} {{ range $i,$profile := $node.Profiles.GetSlice }}
|
||||
{{- if $i }},{{end}}
|
||||
{{- $profile }}{{ end }}
|
||||
{{- range $key,$value := $node.Tags }},{{$value.Get}}{{ end }}
|
||||
{{- end }}
|
||||
25
userdocs/contents/example-templates.rst
Normal file
25
userdocs/contents/example-templates.rst
Normal file
@@ -0,0 +1,25 @@
|
||||
================
|
||||
Useful templates
|
||||
================
|
||||
|
||||
The examples directory contains some useful examples for day to day cluster admninstration.
|
||||
|
||||
Genders
|
||||
=======
|
||||
|
||||
The file `genders.ww` can be placed as `/etc/genders.ww` which will create a genders database which containts all nodes with their profile as key. Also for every user defined 'key' the 'tah' will be added.
|
||||
|
||||
.. Note:
|
||||
|
||||
A arbitrary tag with a key can be added to a node with
|
||||
|
||||
.. code-block:: bash
|
||||
wwctl node set --tagadd key=value n01
|
||||
wwctl node set --tagadd key2='foo=baar' n01
|
||||
|
||||
will result in genders file with following line
|
||||
|
||||
|
||||
.. code-block:: bash
|
||||
n01: value,foo=baar
|
||||
|
||||
Reference in New Issue
Block a user