fixed transports not using /usr/sbin on RHEL

Signed-off-by: David MacMillan <dmac134@gmail.com>
This commit is contained in:
David MacMillan 2019-11-01 10:16:59 -03:00
parent 7031d06df0
commit a5fd0f7acd

View File

@ -15,8 +15,10 @@
include_recipe 'postfix::_common'
postmap_command = platform_family?('rhel') ? '/usr/sbin/postmap' : 'postmap'
execute 'update-postfix-transport' do
command "postmap #{node['postfix']['transport_db']}"
command "#{postmap_command} #{node['postfix']['transport_db']}"
environment PATH: "#{ENV['PATH']}:/opt/omni/bin:/opt/omni/sbin" if platform_family?('omnios')
action :nothing
end