]> gitweb.fluxo.info Git - puppet-git.git/commitdiff
Make inetd optional
authorSilvio Rhatto <rhatto@riseup.net>
Wed, 9 Mar 2016 22:14:37 +0000 (19:14 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Wed, 9 Mar 2016 22:14:37 +0000 (19:14 -0300)
manifests/daemon.pp

index 47746a60fc577a3b0d3ba216564d18ba8fbdbc03..057f778b2f0cbc0670dd6a999dbce0aba0412303 100644 (file)
@@ -1,5 +1,6 @@
 class git::daemon (
   $implementation = hiera('git::daemon::implementation', 'gitolite')
+  $inetd          = hiera('git::daemon::inetd',          true)
 ) {
   # directory for git user and repositories
   file { "/var/git":
@@ -70,15 +71,17 @@ class git::daemon (
   # default implementation
   include git::gitolite
 
-  # the needed packages and services
-  include inetd
+  # include inetd if needed
+  if ($inetd == true) {
+    include inetd
 
-  # git-daemon config in inetd
-  line { "git-daemon-inetd":
-    file   => "/etc/inetd.conf",
-    line   => "git stream tcp nowait git /usr/bin/git git daemon --inetd --verbose --base-path=/var/git/repositories /var/git/repositories",
-    ensure => present,
-    notify => Service['inetd'],
+    # git-daemon config in inetd
+    line { "git-daemon-inetd":
+      file   => "/etc/inetd.conf",
+      line   => "git stream tcp nowait git /usr/bin/git git daemon --inetd --verbose --base-path=/var/git/repositories /var/git/repositories",
+      ensure => present,
+      notify => Service['inetd'],
+    }
   }
 
   # See http://bastian.rieck.ru/blog/posts/2013/gitweb_readme_workflow/