Managing Instance Templates
Crusoe Cloud is currently in private beta. If you do not currently have access, please request access to continue.
Create a new Template
- CLI
- UI
Use the compute templates create
command to create a template:
crusoe compute templates create \
--name myfirsttemplate \
--type c1a.8x \
--location us-east1-a \
--image ubuntu22.04:latest \
--vpc-subnet-id 7a2f1b6a-9e48-4f3c-a0d7-1d9a8c2f3e0b \
--keyfile ~/.ssh/id_ed25519.pub
In order to create a template via the Crusoe Cloud console:
- Visit the Crusoe Cloud console
- Click the "Compute" tab in the left nav
- Select the "Templates" button at the top of the screen
- Click on the button to "Create Template"
- Follow the UI flow to input all required elements
- Click on "Create" to create your template
Creating VMs from Templates
VM creation from a template uses the Bulk VM create method under the hood. This means that the desired number of VMs are created atomically, with automated rollbacks in the event of any instance creation failures.
VMs (and disks created and attached to VMs) also inherit their naming from the template name by default. For example, VMs created from a template called 'test' will be named 'test-1', 'test-2', etc., with disks qualified with a further -disk prefix ('test-disk-1'). This may be overriden during individual creation requests.
- CLI
- UI
Use the compute vms bulk-create
command, passing a template-id
field associated with the chosen template:
crusoe compute vms bulk-create \
--template-id 9b6f2a8c-4e39-1d7a-0c8f-3e0a9b2c8f3e \
--count 3
...
If you are using a global template, you may optionally choose to specify a VPC subnet ID. Additionally, the InfiniBand network and partition IDs must be specified for IB-enabled instances provisioned via a template.
In order to create VMs from an available instance template:
- Visit the Crusoe Cloud console
- Click the "Compute" tab in the left nav
- Select the "Templates" button at the top of the screen
- Click the "Create VMs" icon available in the row of the template you'd like to use
- Specify the number of instances to be created along with any other required fields based on your template type
- Click on "Create" to have the instances created
Updating Templates
Templates once created cannot be modified. You may choose to clone your templates to make changes or delete outdated / unused templates.
Deleting Templates
- CLI
- UI
Use the compute vms delete
command, passing the name of with the template to be deleted.
crusoe compute templates delete --name TEMPLATE_NAME
In order to delete an instance template:
- Visit the Crusoe Cloud console
- Click the "Compute" tab in the left nav
- Select the "Templates" button at the top of the screen
- Click the "Delete" icon associated available on the row of the template you'd like to delete
- Confirm the deletion action by typing in the name