Restart git-pull-hook on changes to itself and its configuration
authorJan Dittberner <jandd@cacert.org>
Sat, 14 Apr 2018 18:12:00 +0000 (20:12 +0200)
committerJan Dittberner <jandd@cacert.org>
Sat, 14 Apr 2018 18:12:00 +0000 (20:12 +0200)
sitemodules/profiles/manifests/puppet_server.pp

index 0730112..eb7a4bb 100644 (file)
@@ -76,9 +76,10 @@ class profiles::puppet_server (
   }
 
   service { 'git-pull-hook':
   }
 
   service { 'git-pull-hook':
-    ensure  => running,
-    enable  => true,
-    require => [
+    ensure    => running,
+    enable    => true,
+    subscribe => [File['/etc/git-pull-hook.ini'], File['/usr/local/sbin/git-pull-hook']],
+    require   => [
       File['/etc/init.d/git-pull-hook'], File['/usr/local/sbin/git-pull-hook'],
       File['/etc/git-pull-hook.ini'],
     ],
       File['/etc/init.d/git-pull-hook'], File['/usr/local/sbin/git-pull-hook'],
       File['/etc/git-pull-hook.ini'],
     ],