7e33272f84
more secure Added SSL caching to speed up SSL requests Add server_tokens to the global config so this can be turned on|off between dev and prod Add proxy_set_header to vhost as different vhosts may require different headers and the global setting is not ideal Minor space formatting so that the generated files are fractionally more readable
38 lines
1.3 KiB
Text
38 lines
1.3 KiB
Text
user <%= scope.lookupvar('nginx::config::nx_daemon_user') %>;
|
|
worker_processes <%= worker_processes %>;
|
|
|
|
error_log <%= scope.lookupvar('nginx::params::nx_logdir')%>/error.log;
|
|
pid <%= scope.lookupvar('nginx::params::nx_pid')%>;
|
|
|
|
events {
|
|
worker_connections <%= worker_connections %>;
|
|
<% if scope.lookupvar('nginx::params::nx_multi_accept') == 'on' %>multi_accept on;<% end %>
|
|
<% if scope.lookupvar('nginx::params::nx_events_use') %>use <%= scope.lookupvar('nginx::params::nx_events_use')%>;<% end %>
|
|
}
|
|
|
|
http {
|
|
include /etc/nginx/mime.types;
|
|
default_type application/octet-stream;
|
|
|
|
access_log <%= scope.lookupvar('nginx::params::nx_logdir')%>/access.log;
|
|
|
|
sendfile <%= scope.lookupvar('nginx::params::nx_sendfile')%>;
|
|
|
|
server_tokens <%= server_tokens %>;
|
|
<% if scope.lookupvar('nginx::params::nx_tcp_nopush') == 'on' %>tcp_nopush on;<% end %>
|
|
|
|
keepalive_timeout <%= scope.lookupvar('nginx::params::nx_keepalive_timeout')%>;
|
|
tcp_nodelay <%= scope.lookupvar('nginx::params::nx_tcp_nodelay')%>;
|
|
|
|
<% if scope.lookupvar('nginx::params::nx_gzip') == 'on' %>
|
|
gzip on;
|
|
gzip_disable "MSIE [1-6]\.(?!.*SV1)";
|
|
<% end %>
|
|
|
|
include /etc/nginx/conf.d/*.conf;
|
|
}
|
|
<% if scope.lookupvar('nginx::mail') %>
|
|
mail {
|
|
include /etc/nginx/conf.mail.d/*.conf;
|
|
}
|
|
<% end -%>
|