From 64889e1ff40874ced24b9bd4ff01d7fb09171c74 Mon Sep 17 00:00:00 2001 From: GilbN Date: Tue, 25 Jun 2019 21:54:42 +0200 Subject: [PATCH] Updated Home (markdown) --- Home.md | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 67 insertions(+), 1 deletion(-) diff --git a/Home.md b/Home.md index ded2881..8b821bd 100644 --- a/Home.md +++ b/Home.md @@ -1 +1,67 @@ -Welcome to the theme.park wiki! +## Setup + +### Subfilter + +As most of these apps doesn't have support for custom CSS you can get around that by using [subfilter](http://nginx.org/en/docs/http/ngx_http_sub_module.html) in Nginx. + +**If you don't know how to reverse proxy an application, please read this first. It's a really great article and will help you understand all the pieces!** + + + +**Add this to your reverse proxy:** +```nginx +proxy_set_header Accept-Encoding ""; +sub_filter +'' +' +'; +sub_filter_once on; +``` +**Where `CUSTOM_CSS.css` is the name of the theme you want!** + + + +**Here is a complete example: ** + +```nginx +# REDIRECT HTTP TRAFFIC TO https://[domain.com] +server { + listen 80; + server_name plpp.domain.com; + return 301 https://$server_name$request_uri; +} +server { + listen 443 ssl http2; + server_name plpp.domain.com; + +#SSL settings + include /config/nginx/ssl.conf + +location / { + proxy_pass http://192.168.1.2:8701; + include /config/nginx/proxy.conf; + proxy_set_header Accept-Encoding ""; + sub_filter + '' + ' + '; + sub_filter_once on; + } +} +``` +**For Apache try this: (UNTESTED)** +```apache +AddOutputFilterByType SUBSTITUTE text/html + Substitute 's| ' +';|' +``` +**Like so** +```apache + + ProxyPass http://localhost:8989/sonarr + ProxyPassReverse http://localhost:8989/sonarr +AddOutputFilterByType SUBSTITUTE text/html + Substitute 's| ' +';|' + +``` \ No newline at end of file