Reputation: 8234
Is it possible to set up RDS in such a way that EC2 instances use the RDS Instance Identifier "mydb" to connect to RDS instead of using the public DNS name : mydb.cfnr64hlvtcp.us-east-1.rds.amazonaws.com
. ?
Upvotes: 7
Views: 12401
Reputation: 536
AWS has documentation for creating RDS CNAME's:
http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-to-rds-db.html
Upvotes: 3
Reputation: 1937
The only way to access an RDS database is by using the public DNS endpoint name generated by RDS when the database is created.
You could setup your own CNAME for the RDS DNS name if you wanted to hide the public DNS name from a component in your system, but then you must maintain that entry, which seems a bit complicated.
AWS strongly recommends that you don't use the IP address behind the RDS DNS entry directly since that IP may change, for example if your database has to failover to a new instance. [1]
[1] http://aws.amazon.com/rds/faqs/#What_is_a_DB_Subnet_Group_and_why_do_I_need_one
Upvotes: 5