header_filter_by_lua
location /demo { proxy_pass http://localhost:3000/demo ; header_filter_by_lua ' local url = ngx.header.Location if not url then return else ngx.header.Location = "http://localhost:3001/newDemo" end '; }
本文共 398 字,大约阅读时间需要 1 分钟。
location /demo { proxy_pass http://localhost:3000/demo ; header_filter_by_lua ' local url = ngx.header.Location if not url then return else ngx.header.Location = "http://localhost:3001/newDemo" end '; }
转载地址:http://zygjx.baihongyu.com/