Skip to content

Commit

Permalink
correct sendmail configuration
Browse files Browse the repository at this point in the history
the `email_` prefix is wrong, the settings have no such prefix

Fixes: 6c902a4
  • Loading branch information
evgeni committed Sep 20, 2023
1 parent cd9f890 commit 9cba747
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions spec/classes/foreman_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,8 @@

it 'should configure certificates in settings.yaml' do
is_expected.to contain_concat__fragment('foreman_settings+01-header.yaml')
.with_content(%r{^:email_sendmail_location: "/usr/bin/mysendmail"$})
.with_content(%r{^:email_sendmail_arguments: "--myargument"$})
.with_content(%r{^:sendmail_location: "/usr/bin/mysendmail"$})
.with_content(%r{^:sendmail_arguments: "--myargument"$})
.with_content(%r{^:websockets_ssl_key: /etc/ssl/private/snakeoil-ws\.pem$})
.with_content(%r{^:websockets_ssl_cert: /etc/ssl/certs/snakeoil-ws\.pem$})
end
Expand Down
4 changes: 2 additions & 2 deletions templates/settings.yaml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@

# Email settings
<% if scope.lookupvar("foreman::email_sendmail_location") -%>
:email_sendmail_location: "<%= scope.lookupvar("foreman::email_sendmail_location") %>"
:sendmail_location: "<%= scope.lookupvar("foreman::email_sendmail_location") %>"
<% end -%>
<% if scope.lookupvar("foreman::email_sendmail_arguments") -%>
:email_sendmail_arguments: "<%= scope.lookupvar("foreman::email_sendmail_arguments") %>"
:sendmail_arguments: "<%= scope.lookupvar("foreman::email_sendmail_arguments") %>"
<% end -%>
<% end -%>

Expand Down

0 comments on commit 9cba747

Please sign in to comment.