1
내가 리디렉션 할 필요가 제외의 nginx 재 작성은 하위 도메인
xxx.example.com/list/
yyy.example.com/list/
zzz.example.com/list/
이것은 정규식해야한다, 그렇지? ..하지만 난 여기 뉴비 야. 미리 Tnx.
내가 리디렉션 할 필요가 제외의 nginx 재 작성은 하위 도메인
xxx.example.com/list/
yyy.example.com/list/
zzz.example.com/list/
이것은 정규식해야한다, 그렇지? ..하지만 난 여기 뉴비 야. 미리 Tnx.
server {
listen 80;
server_name .example.com;
location /list/ {
if ($host !~ ^(xxx|yyy|zzz)\.example\.com) {
return 301 http://demo.example.com/list/;
}
# ....
}
}