diff options
Diffstat (limited to 'manifests')
| -rw-r--r-- | manifests/subsystem/motd.pp | 7 | 
1 files changed, 6 insertions, 1 deletions
diff --git a/manifests/subsystem/motd.pp b/manifests/subsystem/motd.pp index 0ed8cbe..ae59f9b 100644 --- a/manifests/subsystem/motd.pp +++ b/manifests/subsystem/motd.pp @@ -1,11 +1,16 @@  class nodo::subsystem::motd( +  $message      = hiera('nodo::subsystem::motd::message', ''),    $network_name = hiera('nodo::subsystem::motd::network_name', 'Nodo')  ) { +  if $message != '' { +    $append = "${message}\n" +  } +    file { "/etc/motd":      owner   => "root",      group   => "root",      mode    => 0644,      ensure  => file, -    content => "This is ${::fqdn} from the ${network_name}.\n", +    content => "This is ${::fqdn} from the ${network_name}.\n${append}",    }  }  | 
