Connect Lightsail instance to AWS instance in a private subnet

0

Hi - I am trying to access Windows SQL server running in a private subnet in AWS from another Windows instance in Lightsail. There are multiple subnets in the same VPC, some are private and others are public. How can (only) allow Lightsail instance to access DBs in SQL server? Thanks

feita há 2 anos2306 visualizações
1 Resposta
0

Hi.

Lightsail has a VPC peering feature.
However, you can only peer with the default VPC.

https://lightsail.aws.amazon.com/ls/docs/en_us/articles/lightsail-how-to-set-up-vpc-peering-with-aws-resources

If you have an RDS resource other than the default VPC, you can place the NLB in front of the RDS and use the endpoint service to establish a connection route from the default VPC to the RDS with an IP address target.

https://dev.classmethod.jp/articles/nlb-bastion-for-rds/

I have successfully connected to Lightsail-> Endpoint on Default VPC-> NLB-> RDS with this configuration.

profile picture
ESPECIALISTA
iwasa
respondido há 2 anos
profile picture
ESPECIALISTA
avaliado há 9 meses
  • Thanks for your response. Will this configuration also work with connecting to MSSQL DB?

  • Yes. You can also connect with MSSQL.
    Only the port number is different.

  • I tried your scenario and put it together in an article. I verified it with MySQL, but it should work with MSSQL as well.

    https://dev.classmethod.jp/articles/lightsail-connect-vpc-rds/

Você não está conectado. Fazer login para postar uma resposta.

Uma boa resposta responde claramente à pergunta, dá feedback construtivo e incentiva o crescimento profissional de quem perguntou.

Diretrizes para responder a perguntas