Name

ec2-modify-image-attribute

Synopsis

ec2-modify-image-attribute imageid -l -a value
ec2-modify-image-attribute imageid -l -r value
ec2-modify-image-attribute imageid -p productcode [-p productcode]

Modifies an attribute for an image. The -l option specifies launch permission attributes, whereas the -p option specifies product codes.

Examples

# Add access
$ ec2-modify-image-attribute ami-f822a39b -l -a 123456789
launchPermission ami-f822a39b ADD userId 123456789

# Remove access
$ ec2-modify-image-attribute ami-f822a39b -l -r 123456789
launchPermission ami-f822a39b REMOVE userId 123456789

# Add product code
$ ec2-modify-image-attribute ami-f822a39b -p crm114
productCodes ami-f822a39b   productCode crm114

Get Cloud Application Architectures now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.