Answer the question
In order to leave comments, you need to log in
How to optimize the site config?
At the moment it looks like this:
server {
listen 80;
listen [::]:80;
# Redirect all HTTP requests to HTTPS with a 301 Moved Permanently response.
return 301 https://$host$request_uri;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name git.mauladen.ru www.git.mauladen.ru;
# Настройки SSL
ssl_certificate /etc/letsencrypt/live/mauladen.ru/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/mauladen.ru/privkey.pem;
include /etc/letsencrypt/options-ssl-nginx.conf;
location / {
proxy_pass https://git.mauladen.ru:3000;
}
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name mauladen.ru www.mauladen.ru;
root /home/mauladen/mauladen.ru/www;
index index.htm index.html;
# Настройки SSL
ssl_certificate /etc/letsencrypt/live/mauladen.ru/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/mauladen.ru/privkey.pem;
include /etc/letsencrypt/options-ssl-nginx.conf;
location / {
# Перенаправление на 404 если нет нужного файла
try_files $uri $uri/ =404;
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question