]> git.donarmstrong.com Git - dsa-puppet.git/commitdiff
Add initial client configuration
authorTollef Fog Heen <tfheen@err.no>
Sat, 16 Jun 2012 10:44:56 +0000 (12:44 +0200)
committerTollef Fog Heen <tfheen@err.no>
Sat, 16 Jun 2012 10:45:36 +0000 (12:45 +0200)
modules/bacula/manifests/client.pp [new file with mode: 0644]
modules/bacula/templates/bacula-fd.conf.erb [new file with mode: 0644]

diff --git a/modules/bacula/manifests/client.pp b/modules/bacula/manifests/client.pp
new file mode 100644 (file)
index 0000000..4ab2b59
--- /dev/null
@@ -0,0 +1,32 @@
+class bacula::client inherits bacula {
+
+  package {
+    "bacula-client": ensure => installed;
+    "bacula-fd": ensure => installed;
+  }
+
+  service {
+    "bacula-fd":
+      ensure => running,
+      enable => true,
+      hasstatus => true,
+      require => Package["bacula-fd"];
+  }
+
+  file {
+    "/etc/bacula/bacula-fd.conf":
+      content => template("bacula/bacula-fd.conf.erb"),
+      mode => 640,
+      owner => root,
+      group => bacula,
+      require => Package["bacula-fd"],
+      notify  => Exec["bacula-fd restart"]
+      ;
+  }
+
+  exec {
+    "bacula-fd restart":
+      path        => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
+      refreshonly => true;
+  }
+}
diff --git a/modules/bacula/templates/bacula-fd.conf.erb b/modules/bacula/templates/bacula-fd.conf.erb
new file mode 100644 (file)
index 0000000..b222569
--- /dev/null
@@ -0,0 +1,28 @@
+##
+## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
+## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
+##
+#  For Bacula release 5.0.1 (24 February 2010) -- debian 5.0.4
+
+# List Directors who are permitted to contact this File daemon
+Director {
+  Name = <%= bacula_director_name %>
+  Password = "<%= bacula_client_secret %>"
+}
+
+# "Global" File daemon configuration specifications
+FileDaemon {
+  Name = <%= bacula_client_name %>
+  FDport = <%= bacula_client_port %>
+  WorkingDirectory = /var/lib/bacula
+  Pid Directory = /var/run/bacula
+  Maximum Concurrent Jobs = 20
+  FDAddress = <%= fqdn %>
+  Maximum Network Buffer Size =        65536
+}
+
+# Send all messages except skipped files back to Director
+Messages {
+  Name = Standard
+  director = <%=bacula_director_name%> = all, !skipped, !restored
+}