X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;f=modules%2Fbacula%2Fmanifests%2Finit.pp;h=02cf50615db485740b8fa8c3537d89ef0cc87933;hb=778db5721899bfcab35141f8376989a2ae08f320;hp=5eb7e93ffb73575b0a471db2eb76d005a9474784;hpb=75ce99c03293e2df071bcbb7f56694d192652586;p=mirror%2Fdsa-puppet.git diff --git a/modules/bacula/manifests/init.pp b/modules/bacula/manifests/init.pp index 5eb7e93ff..02cf50615 100644 --- a/modules/bacula/manifests/init.pp +++ b/modules/bacula/manifests/init.pp @@ -6,9 +6,9 @@ # @param ssl_server_cert path to TLS server certificate # @param ssl_server_key path to TLS server certificate key # @param email_all email address for all reports -# @param email_error email address for errors (defaults to root@localhost) -# @param email_operator email address for the operator (to mount tapes etc; defaults to root@localhost) -# @param email_daemon email address for messages from the daemon (defaults to root@localhost) +# @param email_error email address for errors +# @param email_operator email address for the operator (to mount tapes etc) +# @param email_daemon email address for messages from the daemon # @param public_addresses this host's public IP addresses. The ones it connects out from and is reachable from outsite. # @param has_ipv4 daemons should listen on ipv4 # @param has_ipv6 daemons should listen on ipv6 @@ -20,9 +20,10 @@ class bacula ( String $ssl_server_key, Optional[String] $email_all = undef, - Optional[String] $email_error = undef, - Optional[String] $email_operator = undef, - Optional[String] $email_daemon = undef, + # default to all if defined, otherwise default to 'root' to enforce error delivery + String $email_error = $email_all ? { undef => 'root', default => $email_all }, + String $email_operator = $email_error, + String $email_daemon = $email_error, Array[Stdlib::IP::Address] $public_addresses = $base::public_addresses, Boolean $has_ipv4 = $bacula::public_addresses.any |$addr| { $addr =~ Stdlib::IP::Address::V4 }, Boolean $has_ipv6 = $bacula::public_addresses.any |$addr| { $addr =~ Stdlib::IP::Address::V6 },