Skip to main content
This guide explains how to launch AWS EC2 instances and register them with Omni. There are two ways to get started:
  • Option A: Use the official Talos AMI — the fastest and recommended approach. Choose this unless you need to customize the image.
  • Option B: Build a custom Talos AMI — use this only if you need system extensions or other image-level customizations.
Both options begin with the same AWS setup. First, complete the steps in Set up your AWS environment, then continue with either Option A or Option B.

Set up your AWS environment

Before launching your instances, configure the AWS networking required for your deployment.

Step 1: Set your AWS region

Define the AWS region where you want to create your Omni machines.

Step 2: Identify the VPC

Your EC2 instances must run inside a VPC. Most AWS accounts have a default VPC available. First list the VPCs in your region:
Then capture the default VPC:
This command stores the VPC ID in the VPC_ID variable.

Step 3: Create a subnet

Next, create a subnet within the VPC. The subnet CIDR must fall within the VPC CIDR range. For example, if the VPC uses 172.31.0.0/16, you can create a subnet such as 172.31.128.0/20.
The subnet ID will be used later when launching EC2 instances.

Step 4: Create a security group

First, create a security group that will be attached to the EC2 instances.
Next, update the security group to allow all internal traffic within the same group. This allows Kubernetes applications running on different machines to communicate with each other:

Option A: Use the official Talos AMI

Talos provides an official AWS AMI that you can use directly, with no image build required.
The official Talos AWS AMI includes the ecr-credential-provider system extension by default.
To register an instance, you add a join config to the EC2 instance user data and boot the instance with the official Talos AMI. The machine then joins your Omni account automatically when it starts.
  1. Define environment variables that specify the machines you want to register. These are example values. Adjust them to match your machine specifications.
  2. Retrieve the official Talos AWS AMI:
  3. Generate the join configuration. This allows the Talos machines to register with Omni when they boot:
  4. Launch the EC2 instances. Omni surfaces an instance’s EC2 tags as machine labels when the machine first joins. Choose the option that fits your needs:
    Launch the instances with the official AMI and your join configuration. The machine registers with Omni automatically when it boots:
Your machine is now registered with Omni and will appear on the Machines page once it joins. To use it, continue to Create a cluster. When you are finished and no longer need these resources, see Cleanup.

Option B: Build a custom Talos AMI

If you need system extensions or other customizations baked into the image, build a custom Talos AMI. In this option, you will:
  1. Download the Talos AWS disk image from Omni
  2. Upload it to Amazon S3
  3. Import it into EC2 as a snapshot
  4. Register the snapshot as an AMI
  5. Launch instances from your custom AMI

Step 1: Download the Talos AWS image

You can download the Talos AWS image from the CLI or the UI:
Run the following command to download the Talos AWS image:
To see available options for adding system extensions:
The downloaded Talos AWS image will contain a compressed archive similar to:
Extract the archive:
This command will produce a disk image similar to disk.raw.

Step 2: Create an S3 bucket

The disk image must be uploaded to an S3 bucket before it can be imported into EC2. Bucket names must be globally unique. The following command creates a bucket with a globally unique name using a timestamp.

Step 3: Upload the disk image to S3

Upload the extracted disk image to the S3 bucket:

Step 4: Import the disk image as an EC2 snapshot

Next, import the uploaded disk image into EC2 as a snapshot.

Step 5: Monitor the snapshot import

You can check the status of the import task using:
Once the import completes, retrieve the snapshot ID:
You will use this snapshot in the next step to register the AMI.

Step 6: Register the AMI

Create an AMI from the snapshot.

Step 7: Launch EC2 instances

Finally, create EC2 instances using your custom AMI.
Your machine is now registered with Omni and will appear on the Machines page once it joins. To use it, continue to Create a cluster.

Cleanup

If you no longer need the resources created in this guide, remove them to avoid unnecessary AWS charges.

Terminate the EC2 instances

Terminate the instances you launched, using their instance IDs:
You can find your instance IDs in the EC2 console, or in the output of the run-instances command you ran earlier.

Deregister the AMI (Option B only)

If you created a custom AMI, deregister it:

Delete the snapshot (Option B only)

After deregistering the AMI, delete the snapshot used to create it:

Remove the disk image from S3 (Option B only)

Delete the uploaded disk image:

Delete the S3 bucket (Option B only)

After removing the object, delete the bucket:

Delete the security group

Remove the security group created for the EC2 instances:

Delete the subnet

Finally, delete the subnet created earlier: