Use the hash variable
[mirror/dsa-puppet.git] / modules / exim / templates / eximconf.erb
index 8c0e5ec..1ea37fe 100644 (file)
@@ -119,7 +119,7 @@ domainlist mailhubdomains = lsearch;/etc/exim4/manualroute
 hostlist reservedaddrs = <%= nodeinfo['reservedaddrs'] %>
 
 <%= out = ""
-if exim_ssl_certs == true
+if has_variable?("exim_ssl_certs") && exim_ssl_certs == "true"
 out = "tls_certificate = /etc/exim4/ssl/thishost.crt
 tls_privatekey = /etc/exim4/ssl/thishost.key
 tls_try_verify_hosts = *
@@ -194,7 +194,7 @@ if nodeinfo['bugsmaster']
   ports << 587
 end
 
-if not nodeinfo['mail_port'].empty?
+if not nodeinfo['mail_port'].to_s.empty?
   ports << nodeinfo['mail_port']
 end
 
@@ -211,7 +211,7 @@ remote_sort_domains = *.debian.org:*.debian.net
 
 pipelining_advertise_hosts = !*
 <%= out = ""
-if has_variable?("exim_ssl_certs") && exim_ssl_certs == true
+if has_variable?("exim_ssl_certs") && exim_ssl_certs == "true"
 out = 'tls_advertise_hosts = *'
 end
 out
@@ -852,7 +852,7 @@ smarthost:
   driver = manualroute
   domains = !+handled_domains
   transport = remote_smtp_smarthost
-  route_list = * ' + smarthost + '
+  route_list = * ' + nodeinfo['smarthost'] + '
   host_find_failed = defer
   same_domain_copy_routing = yes
   no_more