03 / 03

How to build an AMI?

Creating a Custom AMI

Building a custom AMI allows you to bake your software and configurations into a template, enabling faster scaling and consistent deployments. The most common method is creating an image from an existing running or stopped EC2 instance.

Steps to Create an AMI
  1. 1

    Launch an EC2 instance from a base AMI and configure it (install software, updates, etc.).

  2. 2

    In the EC2 Console, select the instance and choose Actions > Image and templates > Create image.

  3. 3

    Provide an image name and description.

  4. 4

    Configure volume settings and choose whether to reboot the instance (reboot is recommended for data integrity).

  5. 5

    Once the AMI status is 'available', you can use it to launch new identical instances.

AWS CLI Command to Create Image