X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fbacula%2Ftemplates%2Fbacula-sd.conf.erb;h=07b839302409fa997cb0c6b29ade60a262054ec0;hb=99bd9bc7031f8142fd6cfdbeff7e9281d7b23da5;hp=586e80daee8e2e92ded247ef4cd79d1c4cdad003;hpb=a964a55270d7645b19bab0c5d5b971d344575a56;p=mirror%2Fdsa-puppet.git diff --git a/modules/bacula/templates/bacula-sd.conf.erb b/modules/bacula/templates/bacula-sd.conf.erb index 586e80dae..07b839302 100644 --- a/modules/bacula/templates/bacula-sd.conf.erb +++ b/modules/bacula/templates/bacula-sd.conf.erb @@ -6,12 +6,30 @@ Storage { Name = <%= @bacula_storage_name %> - SDPort = <%= @bacula_storage_port %> + SDAddresses = { + # bacula, on Debian 9 (stretch), does not resolve a single name + # to both v4 and v6 addresses. Se we can't just say + # ip = { addr = }. Boo. + <%- if scope.lookupvar('site::nodeinfo')['misc']['has_v4_ldap'] -%> + ipv4 = { + # use the hostname rather than the IP address from LDAP, + # as /etc/hosts might have a better answer in case of natted hosts. + addr = <%= @bacula_storage_address %> + port = <%= @bacula_storage_port %> + } + <%- end -%> + <%- if scope.lookupvar('site::nodeinfo')['misc']['has_v6_ldap'] -%> + ipv6 = { + addr = <%= @bacula_storage_address %> + port = <%= @bacula_storage_port %> + } + <%- end -%> + } WorkingDirectory = "/var/lib/bacula" - Pid Directory = "/var/run/bacula" + Pid Directory = "/run/bacula" + Plugin Directory = "/usr/lib/bacula" Maximum Concurrent Jobs = 21 - SDAddress = <%= @bacula_storage_address %> - Heartbeat Interval = 180 + Heartbeat Interval = 60 TLS Enable = yes TLS Require = yes