mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
support local debugging behind nginx w/o certs/ssl
This commit is contained in:
parent
02c69ce43c
commit
2ce51f634b
3 changed files with 36 additions and 1 deletions
|
|
@ -1,6 +1,12 @@
|
|||
version: "3.7"
|
||||
|
||||
services:
|
||||
nginx:
|
||||
ports:
|
||||
- "80:80"
|
||||
volumes:
|
||||
- ./ops/nginx/conf.d.dev:/etc/nginx/conf.d:ro
|
||||
|
||||
api:
|
||||
build:
|
||||
target: build
|
||||
|
|
|
|||
29
ops/nginx/conf.d.dev/filterlists.conf
Normal file
29
ops/nginx/conf.d.dev/filterlists.conf
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
# https://github.com/collinbarrett/FilterLists
|
||||
server {
|
||||
listen 80 default_server;
|
||||
|
||||
include svr-includes/*;
|
||||
|
||||
location ^~ /api {
|
||||
rewrite ^/api/(.*)$ /$1 break;
|
||||
proxy_pass http://api:80;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection keep-alive;
|
||||
proxy_set_header Host $host;
|
||||
proxy_cache_bypass $http_upgrade;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://web:80;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection keep-alive;
|
||||
proxy_set_header Host $host;
|
||||
proxy_cache_bypass $http_upgrade;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
}
|
||||
|
|
@ -34,7 +34,7 @@ server {
|
|||
|
||||
# Redirect http to https
|
||||
server {
|
||||
listen 80;
|
||||
listen 80 default_server;
|
||||
server_name filterlists.com;
|
||||
|
||||
return 301 https://filterlists.com$request_uri;
|
||||
|
|
|
|||
Loading…
Reference in a new issue