Table of Contents
Manifests exist to define which configurations should be applied to a specific host as well as to define which configurations should be applied within a type. Manifests are executed locally and the resulting objects are stored in an internal database.
The same object can be redefined in multiple different manifests as long as the parameters are exactly the same.
In general, manifests are used to define which types are used depending on given conditions.
The initial manifest may for instance contain the following code:
# Always create this file, so other sysadmins know cdist is used. __file /etc/cdist-configured --type file case "$__target_host" in my.server.name) __file /root/bin/ --type directory __file /etc/issue.net --type file --source "$__manifest/issue.net ;; esac
The manifest of the type "nologin" may look like this:
__file /etc/nologin --type file --source "$__type/files/default.nologin"
If you want to describe that something requires something else, just setup the variable "require" to contain the requirements. Multiple requirements can be added white space seperated.
# No dependency __file /etc/cdist-configured # Require above object require="__file/etc/cdist-configured" __link /tmp/cdist-testfile \ --source /etc/cdist-configured --type symbolic # Require two objects require="__file/etc/cdist-configured __link/tmp/cdist-testfile" \ __file /tmp/cdist-another-testfile