server {
location / {
content_by_lua_block {
return ngx.redirect("/new_page.html")
}
}
}ctrl + c
content_by_lua_blocknginx-lua module directive to specify block of Lua code | ngx.redirectredirect to other page (with 302 status code) |
/new_page.htmlURL to redirect to |