Headers at the html page

Maxim Dounin mdounin at mdounin.ru
Mon Nov 25 14:20:37 UTC 2013


Hello!

On Sun, Nov 24, 2013 at 12:47:57AM +0600, Alex toyer wrote:

> Hello All,
> 
> I have erlang web application with cowboy web server and i launched it
> behind nginx reverse proxy.
> 
> My nginx configuration:
> 
> server {
> listen 9090;
> 
> location /test {
> proxy_pass http://localhost:8080;
> proxy_http_version 1.1;
> }
> }
> 
> Where http://localhost:8080 is my cowboy web server. When i'm openning:
> http://localhost:8080/test i see my html page, it's ok,
> 
> Browser shows response headers:
> 
> Transfer-Encoding:chunked
> 
> Server:nginx/1.2.6 (Ubuntu)
> 
> Content-Type:text/html
> 
> Content-Encoding:gzip
> 
> Connection:keep-alive
> 
> It's normal, but... I see the following string right on the my html page:
> 
> "HTTP/1.1 204 No Content connection: close server: Cowboy content-length: 0"
> 
> Why nginx adds this string with headers to the html page? And it occurs
> only if i set up Content-Type: text/html header.

Looks like your backend returns malformed response for some 
reason.  You may try digging further into what your backend 
returns.

-- 
Maxim Dounin
http://nginx.org/en/donation.html



More information about the nginx mailing list