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

I have a beanstalk server that is trying to connect to a postgres db running on a ec2 machine. The ips are unknown as they always change. What kind of security should I allow for the db? Normally you retrict to only your known server ip.

share|improve this question

migrated from stackoverflow.com May 19 '11 at 14:08

This question came from our site for professional and enthusiast programmers.

3 Answers 3

You can use AWS security groups to make your postgres server only accessible to your beanstalk instances. Just set up the security group on the postgres server to only allow incoming traffic from instances in your Beanstalk security group. This is effectively a firewall at the TCP/IP level, but you can block/allow based on AWS security groups instead of IP addresses. As far as I know, this should be pretty darn secure. At least, if you trust that Amazon has implemented its security group feature well.

share|improve this answer

You might find this recent and mildly related pg-performance thread interesting:

http://postgresql.1045698.n5.nabble.com/amazon-ec2-tt4368036.html

In particular:

http://postgresql.1045698.n5.nabble.com/amazon-ec2-tp4368036p4369917.html

share|improve this answer

You can try define VPC security group.

share|improve this answer

Your Answer

 
discard

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