It's just a simple guidance on how to use your domain with a Lightsail instance.
I'll consider a situation when you have bought a domain using Namecheap (could be any domain registrar) and have created a Lightsail instance with Debian.
The complete list of steps will look like:
- Create a
static IP - Create and configure a
DNS zone - Change
networkingsettings - Use AWS
nameserversfor your domain - Install and setup
nginx* - Setup Let's Encrypt
SSLcertificate*
Create a static IP

- Open
Networkingpage - Click on
Create static IP - Pick up a
namefor your static IP - Click on
Create - Open
Networkingpage - Click on your
static IP - Attach it to your
instance
Create and configure a DNS zone

- Open
Domains & DNSpage - Click on
create DNS zone - Specify your registered
domain name - Click on
create DNS zone - Assign your registered
domain nameto your created zone - Add
DNS records
Change networking settings

- Open the page with your
instance - Open
Networking tab - Make sure you have left opened only
portsthat you need (in my case, it's only 22 and 443)
Use AWS nameservers for your domain

- Open
Domains & DNSpage - Open the page with your
DNS zone - Copy your
name servers - Use your
name serversin the dashboard of your domain register (I used Namecheap) - You can use dnschecker to see if changes were applied (it will take some time)
Install and setup nginx*
This topic is skipped because it's pretty basic and available in the internet
Setup Let's Encrypt SSL certificate*
This topic is well covered in the official doc (If you need a free SSL certificate for your site then you can follow this step)
* - optional steps