What Ip do I add to my DB connections whitelist to allow remote connections from my AWS Instances

Expected behavior

I Would like all my Instances in a node cluster to be hosted by the same static public IP address. With this address I can add a rule in our firewall to allow connections from my instances

Actual behavior

The Ip Addresses of the instances keep changing when a redeploy happens

Additional Information

How can I set up my node cluster with AWS so I can whitelist all instances without updating my firewall each time?

Thanks in advanced.

1 Like

Is this firewall in AWS or external? It’s possible you could do something with SecurityGroups to achieve what you need. But if you’re firewall is external it’s unlikely.

What you might consider looking at is adding an elastic IP to the ELB of that Docker for AWS creates. The ELB should not be changing and if you use -p <elb port>:<docker port> in either the command for the service create or in the docker compose or DAB file under the ports section.