У меня есть следующая конфигурация nginx для vhost:
server {
listen 80;
server_name guest8.ellak.gr;
location /.well-known/acme-challenge {
root /var/www/letsencrypt;
}
location / {
rewrite ^ https://$server_name$request_uri? permanent;
}
}
server {
listen 443 ssl;
#Change theese ones
ssl_certificate /etc/letsencrypt/live/guest8.ellak.gr/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/guest8.ellak.gr/privkey.pem;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers HIGH:!aNULL:!MD5;
server_name guest8.ellak.gr;
#To have one site for all piwik analytics
location /piwik/ {
error_page 502 /502.html;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_cache_bypass $http_upgrade;
proxy_pass http://0.0.0.0:8081;
proxy_set_header Host guest8.ellak.org;
}
location /mailcow/ {
error_page 502 /502.html;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_cache_bypass $http_upgrade;
proxy_pass http://0.0.0.0:8099;
proxy_set_header Host guest8.ellak.org;
}
location = /502.html{
root /var/www/ellak.org;
}
}
Я хочу добиться этого, чтобы размещать различные докер-приложения под псевдонимом + с использованием ssl. Но либо посещение http://guest8.ellak.gr/piwik или http://guest8.ellak.org/mailcow Я получаю ошибку 404.
Вы можете помочь мне понять, почему?