Skip to main content

Build Status

ec2imgutils

A collection of utilities for image management in AWS EC2

Installation

openSUSE and SUSE Linux Enterprise

> zypper in python3-ec2imgutils

PyPI

> pip install ec2imgutils

Utilities

ec2deprecateimg

A command line utility to deprecate images in Amazon EC2. The platform does not support a formal deprecation mechanism. The mechansim implemented by this tool is a convention. Unfortunately the tags are not sticky, i.e. not visible to others if the image is shared.

Images are tagged with:

  • Deprecated on -> today's date in YYYYMMDD format
  • Removal date -> today's date plus the deprecation period specified
  • Replacement image -> The AMI ID and name of the replacement image

The image set as the replacement is removed from the list of potential images to be deprecated before any matching takes place. Therefore, the deprecation search criteria specified with --image-name-frag or --image-name-match cannot match the replacement image.

Usage

> ec2deprecateimg --account example --image-name-match v15 --image-virt-type hvm --replacement-name exampleimage_v16

See the man pages for more information.

man ec2deprecateimg

ec2publishimg

A command line utility to control the visibility of an image in AWS EC2. The utility sets the visibility of an AMI to allow others to use the image, making it public or sharing it with sepecific accounts, or setting the image to private, i.e. only available to the account owner.

Usage

> ec2publishimg --account example --image-name-match production-v2 --share-with all

See the man pages for more information.

man ec2publishimg

ec2removeimg

A command line utility to remove images in Amazon EC2. Removing an image, in the sense that all traces of a given image are gone, means the image (AMI) has to be deregistered and the associated snapshot has to be deleted. Having to do this in multiple regions in the UI is tedious and from the the command line is a bookkeeping annoyance. This tool handles the clean up of images.

Usage

> ec2removeimg --account example --image-name-match v15

See the man pages for more information.

man ec2removeimg

ec2uploadimg

A command line utility to upload a compressed raw image file, as created by KIWI for example to Amazon EC2 and create a snapshot or register an EBS backed AMI. Uploads a compressed raw image to Amazon EC2 using an existing EC2 AMI and creates a snapshot or registers a new AMI from the image. The apparent size of the raw image is recommended to be 10 GB or less. It is expected that the raw image has 1 partition, i.e. the root partition is /dev/sda1. The process of creating the image is as follows:

  • Start an instance
  • Create a storage volume and attach it to the running instance
  • Create volume that will be the new root and attach it to the running instance
  • Upload the image
  • Unpack the image and dump it to the new root volume
  • Detach the new root volume and create a snapshot
  • Register a new AMI
  • Clean up

Usage

> ec2uploadimg --account example -d "My first image" -m x86_64 -n my_linux_image -r us-east-1 PATH_TO_COMPRESSED_FILE

See the man pages for more information.

man ec2uploadimg

Metadata

Release files for ec2imgutils 7.0.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ec2imgutils 7.0.6
File Size Uploaded
ec2imgutils-7.0.6.tar.gz 46.2 kB Details

Release files / ec2imgutils-7.0.6.tar.gz

Download URL ec2imgutils-7.0.6.tar.gz
Size 46.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b3b7e4bb36718035c77f21aca78878ea87ce82e81c1b656985e2792886c4c686
BLAKE2b-256 checksum
How to use checksums
390962c3f9480ab10e7cc2ac9268f892e5d71b7bcb342a757284e2f52906b3a9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.4.8

Release history Release notifications | RSS feed

10.0.5

2 release files

10.0.3

2 release files

10.0.2

2 release files

10.0.1

2 release files

10.0.0

2 release files

9.0.4

2 release files

9.0.3

2 release files

9.0.2

2 release files

9.0.1

1 release file

9.0.0

1 release file

8.1.2

1 release file

8.1.1

1 release file

8.1.0

1 release file

7.0.9

1 release file

7.0.8

1 release file

7.0.7

1 release file

This release

7.0.6 This release

1 release file

7.0.5

1 release file

7.0.2

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page