Nginx upstreams and Heroku -


i use nginx upstreams balance 2 instances of application, 1 of them on ec2 server , other on heroku.

the problem is, when put app.herokuapp.com in upstream directive, resolves ip address, , requests sent ip address, heroku uses host identify application, doesn't work.

i'm stuck on this, do?


update: app uses host too, think stuck on this. can't change heroku, guess have add header original request host used application , keep host default, heroku find application

add host header proxy.

proxy_pass http://upstream; proxy_set_header host $host; .... 

Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -