Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

various fixes for use with postfix #2

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion postfix-dkim/recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
#

package 'opendkim'
package 'opendkim-tools'

template "/etc/opendkim.conf" do
source "opendkim.conf.erb"
Expand All @@ -44,10 +45,16 @@
EOH
end

group "opendkim" do
action :modify
members "postfix"
append true
end

service "opendkim" do
action :start
end

service "postfix" do
action :restart
end
end
7 changes: 4 additions & 3 deletions postfix-dkim/templates/default/opendkim.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Syslog yes
# Required to use local socket with MTAs that access the socket as a non-
# privileged user (e.g. Postfix)
#UMask 002
UMask 002

# Sign for example.com with key in /etc/mail/dkim.key using
# selector '2007' (e.g. 2007._domainkey.example.com)
Expand All @@ -24,7 +24,8 @@ SignatureAlgorithm rsa-sha256
SubDomains no
#ADSPDiscard no
#Version rfc4871
X-Header no
X-Header yes
OversignHeaders From

###############################################
# Other (less-standard) configuration options #
Expand Down Expand Up @@ -55,4 +56,4 @@ X-Header no
# be passed through
#RequiredHeaders yes

<%= "SenderHeaders #{node[:postfix_dkim][:sender_headers]}" if node[:postfix_dkim][:sender_headers] %>
<%= "SenderHeaders #{node[:postfix_dkim][:sender_headers]}" if node[:postfix_dkim][:sender_headers] %>