I am returning a stored custom HTML file for a particular request using ngx.exec function. I want to set the right HTTP response code. I am not able to figure out how to do that. Even if I set ngx.status before ngx.exec the response code returned is always 200 to the client.
Is there a way to set the response code?