try fixing subpath proxy

This commit is contained in:
Collin M. Barrett 2019-09-02 16:14:12 -05:00
parent d741ea63c4
commit 552ef3de41
3 changed files with 20 additions and 4 deletions

View file

@ -21,10 +21,7 @@ server {
proxy_set_header X-Forwarded-Proto $scheme;
}
location ^~ / {
if (!-e $request_filename) {
rewrite http://web:80 break;
}
location / {
proxy_pass http://web:80;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;

View file

@ -3,6 +3,7 @@
# init base
FROM nginx:alpine as base
COPY ./src/FilterLists.Web/nginx/conf.d /etc/nginx/conf.d
# init build
FROM node:alpine as build

View file

@ -0,0 +1,18 @@
# https://raw.githubusercontent.com/react-boilerplate/react-boilerplate/master/app/.nginx.conf
##
# Put this file in /etc/nginx/conf.d folder and make sure
# you have a line 'include /etc/nginx/conf.d/*.conf;'
# in your main nginx configuration file
##
server {
listen 80;
# Always serve index.html for any request
location / {
# Set path
root /var/www/;
try_files $uri /index.html;
}
}