From 48ecec64c5f2cf715bb803597c756dd1b934f5c6 Mon Sep 17 00:00:00 2001 From: Greg 'gba' Albrecht Kim Date: Thu, 12 Jul 2012 18:14:08 -0700 Subject: [PATCH] COOK-1442 Adding conditional in case domain is missing (e.g. Vagrant). --- templates/default/main.cf.erb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/default/main.cf.erb b/templates/default/main.cf.erb index 9083ec5..029ce49 100644 --- a/templates/default/main.cf.erb +++ b/templates/default/main.cf.erb @@ -20,7 +20,9 @@ smtp_tls_CAfile = <%= node['postfix']['smtp_tls_cafile'] %> smtp_use_tls = <%= node['postfix']['smtp_use_tls'] %> <% end -%> myhostname = <%= node['postfix']['myhostname'] %> +<% if node['postfix']['domain'] %> mydomain = <%= node['postfix']['mydomain'] %> +<% end -%> myorigin = <%= node['postfix']['myorigin'] %> smtpd_banner = $myhostname ESMTP $mail_name alias_maps = hash:/etc/aliases