EADST

Redirecting a Subpath to a Port with Nginx

Redirecting a Subpath to a Port with Nginx

http://xiedong.me/chat-> http://xiedong.me:2023/

server {
    listen 80;
    server_name xiedong.me www.xiedong.me;

    location ~ ^/chat(/.*)?$ {
        return 301 $scheme://xiedong.me:2023$1;
    }

    location / {
        rewrite ^/(.*)$ http://eadst.com/$1 permanent; # redirect to eadst.com
    }
}
相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
站点统计

本站现有博文242篇,共被浏览292579

本站已经建立1784天!

热门文章
文章归档
回到顶部