Quantcast
Channel: Nginx Forum - Nginx Mailing List - Russian
Viewing all articles
Browse latest Browse all 3102

server location from http to https on same server (no replies)

$
0
0
Всем привет!

Есть конфиг:

server {
listen 80;
server_name domen.com;

location /ua/articles/article1/ { return 301 https://domen.com/blog-item/article1/; }
location /ua/articles/article2/ { return 301 https://domen.com/blog-item/article3/; }
...

location / { return 301 https://domen.com; }
}

server {
listen 80;
server_name www.domen.com;
return 301 https://domen.com;
}

server {
listen 443 ssl;
server_name www.domen.com;
ssl_certificate ...;
ssl_certificate_...;
return 301 https://domen.com;
}

server {
listen 443 ssl;
server_name domen.com;
root /.../public;
ssl_certificate ...;
ssl_certificate_key ...;
...
}

Проблема в:
location /ua/articles/article1/ { return 301 https://domen.com/blog-item/article1/; }
путь в location не определяеться, редирект не происходит, а пытаеться зайти на https://domen.com/ua/articles/article1...
перепробовал уже регулярки в location =, ~*, ... не работает.
куда смотреть?

Viewing all articles
Browse latest Browse all 3102


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>