Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am setting up Nginx servers behind the ELB. I set up so that api.app.com points to an ELB. I wonder which addresses I should use for remote connections, Nginx settings etc..

1) For example, in Nginx:

Should I do

 server {
          listen 80;
#What is the right line here:
#              server_name <WWW.NAME.COM> OR <ec2-.....compute-1.amazonaws.com> OR <MLB-....amazonaws.com>?;
         passenger_enabled on;

2) I connect servers behind ELB to remote Postgres database. In Postgres settings should I open the ELB address (MLB-...amazonws.com) or to individual EC2 IPs?

share|improve this question

1 Answer 1

The server_name should be set to your web site's hostname, that people will actually type in.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.