Answer the question
In order to leave comments, you need to log in
How to make one site address available via http on Nginx?
Now that's how I'm set up. All http requests are directed to https:
server {
listen *:80;
server_name мой сайт;
proxy_set_header Host мой сайт;
location / {
rewrite ^(.*)$ https://мой сайт$1 permanent;
}
}
Answer the question
In order to leave comments, you need to log in
server {
listen *:80;
server_name site;
proxy_set_header Host site;
location ^~ /.well-known/acme-challenge/ {
allow all;
}
location / {
rewrite ^(.*)$ https://site$1 permanent;
}
root /myfolderpath/public;
}
Now you can renew ssl certificates without dancing with a tambourine
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question