server {
listen 80;
listen [::]:80;
# Add index.php to the list if you are using PHP
access_log /var/log/nginx/mushroomer.access.log;
error_log /var/log/nginx/mushroomer.error.log;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://127.0.0.1:8081;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
upstream serve {
server 0.0.0.0:8081;
keepalive 15;
}
server {
listen 80;
listen [::]:80;
# Add index.php to the list if you are using PHP
access_log /var/log/nginx/mushroomer.access.log;
error_log /var/log/nginx/mushroomer.error.log;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://serve;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
upstream serve {
server 127.0.0.1:8081;
keepalive 15;
}
server {
listen 80;
listen [::]:80;
server_name 127.0.0.1;
# Add index.php to the list if you are using PHP
access_log /var/log/nginx/mushroomer.access.log;
error_log /var/log/nginx/mushroomer.error.log;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://serve;
}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}