ec2-register
Description
Registers an AMI with Amazon EC2. Images must be registered before they can be launched. To launch instances, use the RunInstances operation.
Each AMI is associated with an unique ID which is provided by the Amazon EC2 service through the RegisterImage operation. During registration, Amazon EC2 retrieves the specified image manifest from Amazon S3 and verifies that the image is owned by the user registering the image.
The image manifest is retrieved once and stored within the Amazon EC2. Any modifications to an image in Amazon S3 invalidates this registration. If you make changes to an image, deregister the previous image and register the new image. To deregister an image, use the DeregisterImage operation.
Syntax
ec2-register
manifest
Options
| Name | Description | Required |
|---|---|---|
|
Full path to your AMI manifest in Amazon S3 storage. Type: String Default: None Example: mybucket/image.manifest.xml |
Yes |
Output
The command returns a table that contains the following information:
-
IMAGE identifier
-
Unique ID of the newly registered machine image
Amazon EC2 displays errors on stderr.
Examples
Example Request
This example registers the AMI specified in the image.manifest.xml manifest file.
PROMPT>ec2-register mybucket/image.manifest.xmlIMAGE ami-78a54011