default[:apache][:listen_address] = "*"
default[:apache][:ssl][:certificate] = "openstreetmap"
-default[:apache][:ssl][:certificate_chain] = "rapidssl"
default[:apache][:buffered_logs] = true
#
certificate = node[:apache][:ssl][:certificate]
-certificate_chain = node[:apache][:ssl][:certificate_chain]
node.default[:ssl][:certificates] = node[:ssl][:certificates] | [certificate]
apache_conf "ssl" do
template "ssl.erb"
- variables :certificate => certificate, :certificate_chain => certificate_chain
+ variables :certificate => certificate
notifies :reload, "service[apache2]"
end
apache = resources("service[apache2]")
-apache.subscribes(:restart, "cookbook_file[/etc/ssl/certs/#{certificate_chain}.pem]")
apache.subscribes(:restart, "file[/etc/ssl/certs/#{certificate}.pem]")
apache.subscribes(:restart, "file[/etc/ssl/private/#{certificate}.key]")
SSLCertificateFile /etc/ssl/certs/<%= @certificate %>.pem
SSLCertificateKeyFile /etc/ssl/private/<%= @certificate %>.key
-SSLCertificateChainFile /etc/ssl/certs/<%= @certificate_chain %>.pem
SSLUseStapling On
SSLStaplingResponderTimeout 5
},
:apache => {
:ssl => {
- :certificate => "osmfoundation",
- :certificate_chain => "startcom"
+ :certificate => "osmfoundation"
}
},
:dhcpd => {