Creating your own infrastructure container images

Modified: 08 Mar 2023 00:28 UTC

In addition to the Triton-provided images, you can create your own custom images (private to you) for provisioning infrastructure containers. This section describes how.

To learn how to create HVM images, read our documentation.

Creating a custom image in the portal

To create a custom image on the Triton Compute Service portal follow these instructions.

Provision an instance from one of the following images that you want to use as a base. We will call this the prototype instance.

Customize your prototype instance the way you want it.

On the portal under the Compute tab, visit the Instances list and select your prototype instance to view the instance details. Under the Images section, you can create a new image. Give your new image a name, version number, (an optional) description, and Create Image.

Image creation takes a few minutes.

To see all your images and provision new instances, visit the Custom Images list. Select Create Instance and proceed to follow the prompts as per usual, selecting the package and adding metadata. Launch your new instance.

You should see your newly created instance provisioning under Instances.

Creating a custom image with command line tools

To create a custom image that you can use to provision your own instances, you will need the following:

The general procedure for creating a custom image is:

Provision an instance from an image that you want to use as a base. This is the prototype instance.

Customize your instance the way you want.

Execute triton image create with the UUID of the stopped prototype instance to create an image.

It will take several minutes to create an image. The process of creating an image is as follows:

  1. Your instance is stopped to checkpoint the data on the instance so that it can be rolled back to its current state after the process ends.
  2. The prototype instance is rebooted.
  3. A script runs on the prototype instance to clear root and host SSH keys, as well as common log files from the prototype instance.
  4. An image is created from the prototype instance's root volume.
  5. The prototype instance is rebooted to the state of the checkpoint in step 1.

You can check on the progress of image creation with the triton image get <UUID>. While the image is being created, its status will be creating. When the image is ready, its status will be active. If the status is failed, see Troubleshooting Image Creation.

When your image is active, you can use triton instance create to create a new instance based on the image you just created.

To see your custom image and all available Triton infrastructure and VM images, execute triton images.

Considerations and limitations