Change nginx.conf.erb to silence warnings
server_name without '@' was causing deprecation warnings.
This commit is contained in:
parent
a7c15e40ab
commit
6529283e81
1 changed files with 7 additions and 7 deletions
|
@ -1,19 +1,19 @@
|
|||
upstream <%= server_name %> {
|
||||
server unix:<%= scope.lookupvar "boxen::config::socketdir" %>/<%= name %>;
|
||||
upstream <%= @server_name %> {
|
||||
server unix:<%= scope.lookupvar "boxen::config::socketdir" %>/<%= @name %>;
|
||||
}
|
||||
|
||||
server {
|
||||
access_log <%= scope.lookupvar "nginx::config::logdir" %>/<%= name %>.access.log main;
|
||||
access_log <%= scope.lookupvar "nginx::config::logdir" %>/<%= @name %>.access.log main;
|
||||
listen 80;
|
||||
root <%= scope.lookupvar "boxen::config::srcdir" %>/<%= name %>/public;
|
||||
server_name <%= server_name %>;
|
||||
root <%= scope.lookupvar "boxen::config::srcdir" %>/<%= @name %>/public;
|
||||
server_name <%= @server_name %>;
|
||||
|
||||
client_max_body_size 50M;
|
||||
|
||||
error_page 500 502 503 504 /50x.html;
|
||||
|
||||
if ($host ~* "www") {
|
||||
rewrite ^(.*)$ http://<%= server_name %>$1 permanent;
|
||||
rewrite ^(.*)$ http://<%= @server_name %>$1 permanent;
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -31,7 +31,7 @@ server {
|
|||
}
|
||||
|
||||
if (!-f $request_filename) {
|
||||
proxy_pass http://<%= server_name %>;
|
||||
proxy_pass http://<%= @server_name %>;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue