X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/d02429561da1d3ad2b5bbe0ac1108e8fc7774922..b5977d65e97f6fcfccddefedf619de4902e45d31:/cookbooks/imagery/templates/default/nginx_imagery.conf.erb diff --git a/cookbooks/imagery/templates/default/nginx_imagery.conf.erb b/cookbooks/imagery/templates/default/nginx_imagery.conf.erb index 405949e24..20e8d5642 100644 --- a/cookbooks/imagery/templates/default/nginx_imagery.conf.erb +++ b/cookbooks/imagery/templates/default/nginx_imagery.conf.erb @@ -7,6 +7,11 @@ server { return 301 https://$host$request_uri; } +upstream <%= @name %>_fastcgi { + server "unix:/var/run/mapserver-fastcgi/layer-<%= @name %>.socket"; + server "unix:/var/run/mapserver-fastcgi/layer-<%= @name %>.socket"; +} + server { listen [::]:443 ssl; listen *:443 ssl; @@ -14,6 +19,10 @@ server { ssl_certificate /etc/ssl/certs/<%= @name %>.pem; ssl_certificate_key /etc/ssl/private/<%= @name %>.key; +<% if node[:ssl][:strict_transport_security] -%> + + add_header Strict-Transport-Security "<%= node[:ssl][:strict_transport_security] %>" always; +<% end -%> root "/srv/<%= @name %>";