2020-07-15 01:40:40 +02:00
|
|
|
## Version 2020/03/05 - Changelog: https://github.com/linuxserver/docker-letsencrypt/commits/master/root/defaults/default
|
|
|
|
|
|
|
|
# redirect all traffic to https
|
|
|
|
server {
|
|
|
|
listen 80 default_server;
|
|
|
|
listen [::]:80 default_server;
|
|
|
|
server_name _;
|
|
|
|
return 301 https://$host$request_uri;
|
|
|
|
}
|
|
|
|
|
2020-07-17 16:22:00 +02:00
|
|
|
# Default to showing 404 on unknown subdomain or missing host header
|
2020-07-15 01:40:40 +02:00
|
|
|
server {
|
|
|
|
listen 443 ssl http2 default_server;
|
|
|
|
listen [::]:443 ssl http2 default_server;
|
|
|
|
|
2020-07-17 16:22:00 +02:00
|
|
|
server_name _;
|
|
|
|
|
|
|
|
# all ssl related config moved to ssl.conf
|
|
|
|
include /config/nginx/ssl.conf;
|
|
|
|
|
|
|
|
return 404;
|
|
|
|
}
|
|
|
|
|
|
|
|
# main server block
|
|
|
|
server {
|
|
|
|
listen 443 ssl http2;
|
|
|
|
listen [::]:443 ssl http2;
|
|
|
|
|
2020-07-15 01:40:40 +02:00
|
|
|
root /config/www/hugo;
|
|
|
|
index index.html;
|
|
|
|
|
2021-02-08 12:15:17 +01:00
|
|
|
server_name old.belanyi.fr;
|
2020-07-15 01:40:40 +02:00
|
|
|
|
|
|
|
# all ssl related config moved to ssl.conf
|
|
|
|
include /config/nginx/ssl.conf;
|
|
|
|
|
|
|
|
client_max_body_size 0;
|
|
|
|
|
2020-07-15 02:53:59 +02:00
|
|
|
# Matrix configuration
|
|
|
|
location /.well-known/matrix/server {
|
|
|
|
default_type application/json;
|
|
|
|
return 200 '{"m.server": "matrix.belanyi.fr:443"}';
|
|
|
|
}
|
|
|
|
|
2020-07-15 01:40:40 +02:00
|
|
|
}
|
|
|
|
|
2020-07-16 12:15:49 +02:00
|
|
|
# Debug version
|
|
|
|
server {
|
|
|
|
listen 443 ssl;
|
|
|
|
listen [::]:443 ssl;
|
|
|
|
|
|
|
|
root /config/www/hugo-dev;
|
|
|
|
index index.html;
|
|
|
|
|
2021-02-08 12:15:17 +01:00
|
|
|
server_name dev.old.belanyi.fr;
|
2020-07-16 12:15:49 +02:00
|
|
|
|
|
|
|
# all ssl related config moved to ssl.conf
|
|
|
|
include /config/nginx/ssl.conf;
|
|
|
|
|
|
|
|
client_max_body_size 0;
|
|
|
|
|
|
|
|
location / {
|
2020-07-16 13:59:11 +02:00
|
|
|
try_files $uri $uri/ =404;
|
2020-07-16 12:15:49 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-07-15 01:40:40 +02:00
|
|
|
# CV block
|
|
|
|
server {
|
|
|
|
listen 443 ssl;
|
|
|
|
listen [::]:443 ssl;
|
|
|
|
|
|
|
|
root /config/www/cv;
|
|
|
|
|
|
|
|
server_name cv.*;
|
|
|
|
|
|
|
|
# all ssl related config moved to ssl.conf
|
|
|
|
include /config/nginx/ssl.conf;
|
|
|
|
|
|
|
|
client_max_body_size 0;
|
|
|
|
}
|
|
|
|
|
2021-01-13 16:38:19 +01:00
|
|
|
# Keys
|
|
|
|
server {
|
|
|
|
listen 443 ssl;
|
|
|
|
listen [::]:443 ssl;
|
|
|
|
|
|
|
|
root /config/www/key;
|
|
|
|
|
|
|
|
server_name key.*;
|
|
|
|
|
|
|
|
# all ssl related config moved to ssl.conf
|
|
|
|
include /config/nginx/ssl.conf;
|
|
|
|
|
|
|
|
client_max_body_size 0;
|
|
|
|
}
|
|
|
|
|
2020-07-15 01:40:40 +02:00
|
|
|
# enable subdomain method reverse proxy confs
|
|
|
|
include /config/nginx/proxy-confs/*.subdomain.conf;
|
|
|
|
# enable proxy cache for auth
|
|
|
|
proxy_cache_path cache/ keys_zone=auth_cache:10m;
|