If you are a beginner to AWS and looking to deploy some servers for your software then AWS Lightsail may be the most useful starting point for you. Unlike Amazon EC2, you are provided with a nice interface where you can choose pre-configured plans that may include most of your use cases.
Just with 3–4 clicks you can start a WordPress website working on Linux server. You also don’t need to worry about managing the cost since the cost is fixed monthly.
Along with servers, you can further build databases, load balancers, and storage on Lightsail. Now let’s take practical and immediately launch a Node server with Lightsail!
Create an Instance in Amazon light sail.
- First, login your AWS console and see in the All Services tab under Compute you will see Lightsail. Click on it, it will execute the Lightsail dashboard in a new tab.
- Now you can choose the region in which you want to build your instance (server). Normally, the closer your instance is to your client, the smaller is the latency and faster is the connection. Here, I have chosen the Delhi region since it’s nearest to my location.
How to create an instance
- Next step is to choose the instance image (OS and application). For the Linux platform, you can either choose only OS where you have the option to select from Ubuntu, OpenSUSE, CentOS or Amazon Linux.
Or you can choose an application on with OS. When you choose an application, AWS automatically establishes all the necessary packages and files required to work with that application so you don’t have to fix them yourself.
Currently, for Windows Server, the only workable app is SQL server.
For the Apps, I will be choosing Node.js here, you can choose anything else if you want.
- In the optional segment above you can join a launch script, this is a shell script that will work on the instance the first time it starts. If you have deployed an EC2 instance in the past then you may evoke that it coincides with the User data there.
- You can apply this script to do some arrangement on the instance.
- Now, its time to pick an instance plan. You can observe the different fixed price feasible plans. If you are trying for the first time then you can practice the first plan worth $3.5 free for one month.
- You can provide your instance with an individual name if you would like.
- You can also assign tags to your instances to quickly filter them or prepare them for billings and analysis purposes.
- Now push Create Instance button to build your first Lightsail instance!
- Inside a few minutes, your server will be stationed and you will view something like above. Click on it to watch additional details.
- You can recognise that the status is working and just below it you can see the Public IP of the instance. If you copy it and paste it in the address bar of your browser it will give you a similar page like below.
- Now you can do SSH into your own instance and use your code.
Don’t forget to stop your instance if you are not practising it anymore. You can stop the instance by using the Delete tab in the above screenshot.
If you loved this article, please give some claps so it reaches more people who would like it!