Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AWS Lightsail - Static IP not visible in ifconfig

I have created AWS Lightsail instance and attached a public IP address. So Curranty machine has 2 IPs, public and private.

the command ifconfig shows only private IP and nowhere in public. Hence I am unable to bind my golang based application to public IP address.

Am I missing anything here? I have spend 1 hour on chasing this and could not see any article that could relate to this, need help.

like image 966
Ankur Avatar asked Nov 28 '25 11:11

Ankur


1 Answers

AWS provides static IPs via NAT. The static IP is part of the AWS network, and traffic to that IP will be routed to the private IP of your instance within the AWS network.

like image 161
Mark B Avatar answered Nov 30 '25 01:11

Mark B