diff --git a/NEWS b/NEWS index 36d581e9e18a76cd3ccf537d1b9e0c37a52639d8..4c483fa64dab3417afc4572bbabf63d13478313f 100644 --- a/NEWS +++ b/NEWS @@ -1,9 +1,11 @@ Unreleased - [dns] Changes Livermore detection to use the system's primary IP address, + [systemd] New class to allow systemd daemon reloads. (adamhl) + + [dns] Changes Livermore detection to use the system's primary IP address, instead of using a manually-set parameter. (akkornel) - [kerberos] Automatically determine if we are in Livermore; if we are, place + [kerberos] Automatically determine if we are in Livermore; if we are, place the Livermore-based KDC at the top of the list. (akkornel) Clients who are using the base::kerberos::dr class should immediately switch diff --git a/manifests/systemd.pp b/manifests/systemd.pp new file mode 100644 index 0000000000000000000000000000000000000000..604e87531a0461e19595029c53cf0b9eea18b9d6 --- /dev/null +++ b/manifests/systemd.pp @@ -0,0 +1,32 @@ +# This code is from the Puppet Forge project justin8-systemd +# +# If you want to reload the systemd service on a unit file change, include +# this class and add a dependency: +# +# notify => Exec['systemd-daemon-reload'] +# + +class systemd { + + exec { 'systemd-daemon-reload': + path => '/bin:/usr/bin:/sbin:/usr/sbin', + command => 'systemctl daemon-reload', + refreshonly => true, + } + + case $::osfamily { + 'Archlinux': { + $unit_path = '/usr/lib/systemd/system' + } + 'Debian': { + $unit_path = '/lib/systemd/system' + } + 'RedHat': { + $unit_path = '/usr/lib/systemd/system' + } + default: { + $unit_path = '/usr/lib/systemd/system' + } + } + +}