Commit f6bf9d02 authored by Marin Jankovski's avatar Marin Jankovski

Merge branch 'fix-non-nil-checks' into 'master'

Attributes with an empty string are not nil...

See merge request !47
parents 8097d165 ed557723
......@@ -77,51 +77,51 @@ ssl = attributes_with_secrets['ssl']
file node['omnibus-gitlab']['gitlab_rb']['nginx']['ssl_certificate'] do
content ssl['certificate']
not_if { ssl['certificate'].nil? }
not_if { ssl['certificate'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['nginx']['ssl_certificate_key'] do
content ssl['private_key']
not_if { ssl['private_key'].nil? }
not_if { ssl['private_key'].empty? }
mode '0600'
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['mattermost-nginx']['ssl_certificate'] do
content ssl['mattermost_certificate']
not_if { ssl['mattermost_certificate'].nil? }
not_if { ssl['mattermost_certificate'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['mattermost-nginx']['ssl_certificate_key'] do
content ssl['mattermost_private_key']
not_if { ssl['mattermost_private_key'].nil? }
not_if { ssl['mattermost_private_key'].empty? }
mode '0600'
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['pages-nginx']['ssl_certificate'] do
content ssl['pages_certificate']
not_if { ssl['pages_certificate'].nil? }
not_if { ssl['pages_certificate'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['pages-nginx']['ssl_certificate_key'] do
content ssl['pages_private_key']
not_if { ssl['pages_private_key'].nil? }
not_if { ssl['pages_private_key'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['registry-nginx']['ssl_certificate'] do
content ssl['registry_certificate']
not_if { ssl['registry_certificate'].nil? }
not_if { ssl['registry_certificate'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
file node['omnibus-gitlab']['gitlab_rb']['registry-nginx']['ssl_certificate_key'] do
content ssl['registry_private_key']
not_if { ssl['registry_private_key'].nil? }
not_if { ssl['registry_private_key'].empty? }
notifies :run, 'bash[reload nginx configuration]'
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment