Created
July 24, 2017 18:42
-
-
Save ironicbadger/e9d149f604eb074a0f5d7efe1db9ca91 to your computer and use it in GitHub Desktop.
nginx-reverse-proxy-chbmb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name www.server.com; | |
return 301 https://server.com$request_uri; | |
} | |
server { | |
listen 443; | |
server_name www.server.com; | |
return 301 https://server.com$request_uri; | |
} | |
server { | |
listen 80; | |
server_name server.com; | |
return 301 https://server.com$request_uri; | |
} | |
server { | |
listen 443 ssl default_server; | |
server_name server.com; | |
add_header Front-End-Https on; | |
root /config/www; | |
index index.html index.htm index.php; | |
location ~ \.php$ { | |
fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
# With php5-cgi alone: | |
fastcgi_pass 127.0.0.1:9000; | |
# With php5-fpm: | |
#fastcgi_pass unix:/var/run/php5-fpm.sock; | |
fastcgi_index index.php; | |
include /etc/nginx/fastcgi_params; | |
} | |
location /books { | |
proxy_pass http://192.168.0.1:9083; | |
proxy_set_header Host $http_host; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_set_header X-Scheme $scheme; | |
proxy_set_header X-Script-Name /books; | |
} | |
#location ^~/books { | |
# proxy_pass http://192.168.0.1:82/; | |
# rewrite /books/?(.*) /$1 break; | |
# auth_basic "Restricted"; | |
# auth_basic_user_file /config/nginx/.htpasswd; | |
# include /config/nginx/proxy.conf; | |
#} | |
location /booksonic { | |
proxy_pass http://192.168.0.1:4040/booksonic; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
} | |
location /couch { | |
proxy_pass http://192.168.0.1:5050/couch; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /deluge { | |
proxy_pass http://192.168.0.1:8112/; | |
proxy_set_header X-Deluge-Base "/deluge/"; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /headphones { | |
proxy_pass http://192.168.0.1:8178/headphones; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /htpc { | |
proxy_pass http://192.168.0.1:8085/htpc; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /lazylibrarian { | |
proxy_pass http://192.168.0.1:5299/lazylibrarian; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /mylar { | |
proxy_pass http://192.168.0.1:8090/mylar; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /nzbget { | |
proxy_pass http://192.168.0.1:6789/nzbget; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /nzbhydra { | |
proxy_pass http://192.168.0.1:5075/nzbhydra; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /plex { | |
proxy_pass http://192.168.0.150:32400/web; | |
include /config/nginx/proxy.conf; | |
} | |
location /web { | |
proxy_pass http://192.168.0.150:32400/web; | |
include /config/nginx/proxy.conf; | |
} | |
location /plexpy/ { | |
proxy_pass http://192.168.0.1:8181; | |
include /config/nginx/proxy.conf; | |
proxy_bind $server_addr; | |
proxy_set_header X-Forwarded-Host $server_name; | |
proxy_set_header X-Forwarded-Ssl on; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
} | |
location /requests { | |
proxy_pass http://192.168.0.1:3579/requests; | |
include /config/nginx/proxy.conf; | |
} | |
location /radarr { | |
proxy_pass http://192.168.0.1:7878/radarr; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /sonarr { | |
proxy_pass http://192.168.0.1:8989/sonarr; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
location /ubooquity { | |
proxy_pass http://192.168.0.1:2202/ubooquity; | |
auth_basic "Restricted"; | |
auth_basic_user_file /config/nginx/.htpasswd; | |
include /config/nginx/proxy.conf; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment