What is AWS AMI (Amazon Machine Image)
When launching an AWS EC2 instance you must have selected an operating system and its version by selecting an AMI. This AMI is an image just like any other container image, let's say like a docker image for example. The difference is that while the docker images are portable lightweight packages that include applications and its dependencies, AMIs are the images of virtual machine instances that contain an entire operating system, software, and configuration.
What is a Custom AMI
Custom AMI is normal AMI plus the changes and configurations made in the EC2 instance. When you make a custom AMI you essentially make the image of the AWS EC2 Instance's storage.
So let's say you make a custom AMI of your EC2 instance which has the Nginx server installed and configured when you launch another EC2 instance using this custom AMI, the newly launched instance will have the Nginx server installed and configured by default exactly as the Nginx was configured in the instance from which the custom AMI was made, hence the newly launched instance will be the exact copy of the instance from which custom AMI was made.
3 Reasons Why You Need To Start Using AMI
1. Faster Scaling
When you use a custom AMI your instance will scale faster i.e when the EC2 instance gets scaled and a new instance is launched, the newly launched instance will be ready to serve faster as compared to the approach wherein you would typically use a configuration management tool like ansible, puppet or chef.
This will be because a configuration management tool will take time to download, install and configure your software and its dependencies while with a custom AMI, the newly scaled instance will have all that by default.
2. Cost Efficiency
In cloud computing, you pay for the compute resources you use. With a configuration management approach, you'll pay for the time it takes to install and configure the software after the instance is launched.
This extra time translates to additional compute costs. In contrast, custom AMIs reduce this extra compute cost because the instance is ready to serve as soon as it's launched. For large-scale applications or those with rapid scaling requirements, this can result in significant cost savings over time.
3. Share, Buy and Sell AMI
Share: you can make your custom AMI public and share it with the community or you can use a shared AMI. Although Amazon does not vouch for the integrity or security of AMIs shared by other Amazon EC2 users. Therefore, you should treat shared AMIs as you would any foreign code that you might consider deploying, it is recommended using AMIs that are owned by Amazon or a verified Amazon partner are marked Verified provider.
Buy: a paid AMI is an AMI that you can purchase from a developer. Amazon EC2 integrates with AWS Marketplace, enabling developers to charge other Amazon EC2 users for the use of their AMIs or to provide support for instances.
Sell: You can sell your custom AMI using AWS Marketplace and make some moneyπ€π€
That's it for this blog, show your support if you like the blog by reacting to the blog and following meπ***. If you have any thoughts to share, feel free to comment your thoughts.***
******Thank you for readingππ******