Fix bacula email logic
authorPeter Palfrader <peter@palfrader.org>
Wed, 25 Sep 2019 17:01:35 +0000 (19:01 +0200)
committerPeter Palfrader <peter@palfrader.org>
Wed, 25 Sep 2019 17:01:35 +0000 (19:01 +0200)
data/common.yaml
modules/bacula/manifests/init.pp

index a4c5ac6..06f0d03 100644 (file)
@@ -33,7 +33,6 @@ roles::dns_primary::allow_access:
 # bacula
 #
 bacula::email_all: 'bacula-reports@admin.debian.org'
-bacula::email_error: 'bacula-reports@admin.debian.org'
 bacula::ssl_ca_path:     '/etc/ssl/debian/certs/ca.crt'
 bacula::ssl_client_cert: '/etc/ssl/debian/certs/thishost.crt'
 bacula::ssl_client_key:  '/etc/ssl/private/thishost.key'
index 90e42af..cf83a26 100644 (file)
@@ -20,7 +20,7 @@ class bacula (
   String $ssl_server_key,
 
   Optional[String] $email_all = undef,
-  String $email_error                          = $email_all ? { true => $email_all, default => 'root@localhost' },
+  String $email_error                          = $email_all != undef ? { true => $email_all, default => 'root@localhost' },
   String $email_operator                       = $email_error,
   String $email_daemon                         = $email_error,
   Array[Stdlib::IP::Address] $public_addresses = $base::public_addresses,