update namespaces

This commit is contained in:
ghost 2023-12-03 23:33:26 +02:00
parent 1bcd1d943a
commit 3a9a30b11f
61 changed files with 857 additions and 856 deletions

View file

@ -0,0 +1,17 @@
# Nginx proxy configuration for texty.org.ua.bro.ygg
Current implementation drops all JS and forward links to following locations:
* `texty.org.ua` > `texty.org.ua.bro.ygg`
## Install
* `ln -s /etc/yggbro/nginx/texty.org.ua/texty.org.ua.bro.ygg/server.conf /etc/nginx/sites-enabled/yggbro.texty.org.ua.texty.org.ua.bro.ygg.conf`
* `nginx -t`
* `service nginx reload`
## Uninstall
* `rm /etc/nginx/sites-enabled/yggbro.texty.org.ua.texty.org.ua.bro.ygg.conf`
* `nginx -t`
* `service nginx reload`

View file

@ -0,0 +1,38 @@
server {
# HTTP/IPv6 only
listen [::]:80;
# Yggdrasil only
allow 0200::/7;
deny all;
server_name texty.org.ua.bro.ygg;
location / {
# Forward to server
proxy_pass https://texty.org.ua/;
# Tell to server, that's proxy request
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
# Replace links
sub_filter_once off;
sub_filter_types *;
sub_filter 'http://texty.org.ua' 'http://texty.org.ua.bro.ygg';
sub_filter 'https://texty.org.ua' 'http://texty.org.ua.bro.ygg';
sub_filter '<script' '<!-- <script';
sub_filter '</script>' '</script> -->';
sub_filter 'href="/support/"' 'href="https://texty.org.ua/p/support"';
sub_filter 'href="/' 'href="http://texty.org.ua.bro.ygg/';
sub_filter 'src="/' 'src="http://texty.org.ua.bro.ygg/';
sub_filter 'data-src="/' 'src="http://texty.org.ua.bro.ygg/';
sub_filter "url('/" "url('http://texty.org.ua.bro.ygg/";
# Feedback link to project repository
sub_filter '</body>' '<a style="position:fixed;top:20px;right:20px;z-index:999" href="https://github.com/YGGverse/YGGbro/tree/main/nginx/texty.org.ua/texty.org.ua.bro.ygg" target="_blank">YGGbro</a></body>';
}
}