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;
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 %>";