nginx通過url跳轉到另外的一個url上

#user nobody;
worker_processes 1;

events {
worker_connections 1024;
}

http {
sendfile on;
server {
listen 7080;
server_name localhost;

     location ^~ /demo { 
    proxy_pass http://127.0.0.1/;
}
location / {  
    root html;
    index index.html index.htm;
}
}

}

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章