Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Connect to Aurora Serverless using EC2 as Proxy

Not a duplicate of AWS Aurora MySQL serverless: how to connect from MySQL Workbench.

Aurora Serverless doesn't support public connections yet.

I used Cloud9 to create an EC2 instance on the same VPN as the database. I then connected to the database from the Cloud9 terminal.

My (GraphQL Prisma) service that I'm attempting to host (on Zeit Now) only takes a HOST and a PASSWORD for configuration.

How can I make the EC2 instance act as a proxy that I can treat exactly as a database endpoint. Can tunneling fully do that and I'm just bad at it?

like image 378
mattferrin Avatar asked Nov 07 '22 02:11

mattferrin


1 Answers

I think this blog may help you. The idea, is make a forwarding port from ec2-dns:3306 to aurora-serverless-cluster-dns:3306

like image 188
Vladimir Venegas Avatar answered Nov 13 '22 16:11

Vladimir Venegas