diff --git a/.gitignore b/.gitignore index 2b30f05..95561ee 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ volumes/html/* !volumes/logs/ !volumes/html/registry.zinomedia.de !volumes/html/registryui.zinomedia.de +!volumes/html/mtail.zinomedia.de # Ignore contents of these directories volumes/html/dl.zinomedia.de/* diff --git a/volumes/conf.d/mtail.zinomedia.de.conf b/volumes/conf.d/mtail.zinomedia.de.conf new file mode 100644 index 0000000..5fe92e5 --- /dev/null +++ b/volumes/conf.d/mtail.zinomedia.de.conf @@ -0,0 +1,38 @@ +server { + listen *:443 ssl; + listen [::]:443 ssl; + server_name mtail.zinomedia.de; + + access_log off; + error_log /var/log/nginx/error.log error; + + ssl_certificate /etc/letsencrypt/live/mtail.zinomedia.de/fullchain.pem; + ssl_certificate_key /etc/letsencrypt/live/mtail.zinomedia.de/privkey.pem; + + include "snippets/ssl-optimizations.conf"; + + location / { + resolver 127.0.0.11; + set $upstream "mtail:3903"; + + # Password protect + auth_basic "Protected"; + auth_basic_user_file /usr/share/nginx/html/mtail.zinomedia.de/.htpasswd; + + proxy_set_header X-Forwarded-Host $host:$server_port; + proxy_set_header X-Forwarded-Server $host; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_http_version 1.1; + proxy_read_timeout 300s; + + proxy_pass http://$upstream; + } + +} + +server { + server_name mtail.zinomedia.de; + listen 80; + listen [::]:80; + return 301 https://$host$request_uri; +} \ No newline at end of file diff --git a/volumes/html/mtail.zinomedia.de/.gitkeep b/volumes/html/mtail.zinomedia.de/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/volumes/html/mtail.zinomedia.de/.htpasswd b/volumes/html/mtail.zinomedia.de/.htpasswd new file mode 100644 index 0000000..ba5e772 --- /dev/null +++ b/volumes/html/mtail.zinomedia.de/.htpasswd @@ -0,0 +1 @@ +zino:$apr1$XBzEVqBi$9SNhwAwBS2PJ47coYKoRH/ \ No newline at end of file