AWS Lightsail - Accessing a mysql database in a different account?

0

I have 2 accounts (root user) set up. They are in the same region.

One account (call it 'Account A') has a mysql database instance with multiple database schemas.

The other account (call it 'Account B') has the webserver (we have an external developer building the web site which accesses the database schema).

I have tried doing a simple mysql connection (using the mysql client on the ubuntu server) try and access Account A's database. However, I get an 'access denied'. I have a feeling it may be because the database isn't open to the public. Is there anyway to do this securely?

Has anybody done this successfully?

Many Thanks for any help!

dipens
질문됨 3년 전480회 조회
2개 답변
0

You would have to open the public ports for mysql.

Each account has it's own VPC. All instances in that VPC can access each other using the VPC, but no other instances.

I blogged about it here: https://www.geekyramblings.net/2019/03/22/lightsail-network-isolation/

david

profile picture
David G
답변함 3년 전
0

Thank you for the detail.

dipens
답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠