Virtual Machines

To create a VM, start by creating a boot disk, and optionally one or more storage disks and security groups. Then follow the instructions below.

Public IP resources

VMs are automatically assigned a private IPv4 address within your network.

It is possible to create a public IP for a VM by running:

$ evroc networking publicip create mypublicip
mypublicip creation requested

SSH access to the VM

See the page on SSH access to VMs.

Creating a Virtual Machine

Once you have created your boot disk, and any security groups, placement groups, public IPs, and SSH keys, it is now possible to create a VM.

If you do not need access into your VM from the internet, then you can skip specifying any public IPs. In such a case, you will likely have a secondary VM, or 'jumpbox', which does have a public IP which is used to access this VM.

Create a VM referencing your boot disk and selecting a virtual resource profile (also known as vmvirtualresourcesref) from the table above:

$ evroc compute vm create myvm --running=True --vm-virtual-resources-ref=general.s --disk=mybootdisk --boot-from=true
myvm creation requested

The command accepts the following parameters:

  • --running: setting this to true means asking for the VM to be running. On create, set this to true. If you want your VM to boot immediately. If omitted, then the default behaviour is 'true'.
  • --vm-virtual-resources-ref: (Required) Specify the resource profile. This cannot be changed after initial create.
  • --disk: (Required) Reference to a previously created Disk. Can be specified multiple times to attach multiple Disks to the VM.
  • --boot-from: (Required) Whether the VM should boot from this Disk. This cannot be changed after initial create, and must be specified for each Disk.
  • --public-ip: (Optional) Reference to a previously created Public IP.
  • --ssh-authorized-key: (Optional) Public key to provision into the VM as an authorized key on first boot. This can be supplied multiple times to add multiple keys
  • --security-group: (Optional) The security group to add the VM to. This can be supplied multiple times to add multiple keys

Note: While specifying security groups is optional, VMs not in security groups will by default get no ingress accesss and will be inaccessible, read the security group docs for more information.

  • --placement-group: (Optional) The placement group to add the VM to.
  • --cloud-init-user-data: (Optional) CloudInit user data passed to the VM. This is either a base64 string or multi-line string. See the docs for more information

For example, to create a VM with a storage disk, public IP and an SSH key:

evroc compute vm create myvm --running=True --vm-virtual-resources-ref=general.s --disk=mybootdisk --boot-from=true --disk=mydisk --boot-from=false --public-ip=mypublicip --ssh-authorized-key="ssh-rsa ..."

Alternatively, you can use the evroc apply command to apply a definition of a boot disk from a file. See the API docs for more details.

Note: If creating a VM with GPUs, see also the page on GPU VMs here.

Note: If you want to use custom cloud-init, follow the docs.

Listing Virtual Machines

$ evroc compute vm list

 Name       Ready   Reason   VirtualMachineStatus   IP          Public IP
---------- ------- -------- ---------------------- ----------- -----------
myVM        True    Ready    Running                10.0.0.50  193.0.0.1

Stopping and Starting a VM

To stop a running VM run:

evroc compute vm update myvm --running=False

To start a currently running VM, run:

evroc compute vm update myvm --running=True

Updating a VM

The following fields on the VM can be updated after creation:

  • --running
  • --public-ip
  • --security-group

Updating a VM's placement group

To switch the VM from being in one placement group to another, you must first stop your virtual machine, then change the placement group field and restart your virtual machine.

Run:

evroc compute vm update myvm --running=False

Then, run:

evroc compute vm update myvm --placement-group=my-pg --running=True

You can add additional storage Disks to your VM after creation using the --append flag:

evroc compute vm update <vm_name> --append --disk=<disk_name>

Deleting a Virtual Machine

$ evroc compute vm delete myvm
myvm deletion requested

Show Virtual Machine

$ evroc compute vm show myVM --verbose
name: myVM
resourceGroup: corveco
createdAt: 2025-05-28 16:13:17 +0000 UTC (1003h7m3s)

== Metadata ============================
finalizers:
  - virtualmachine.compute.evroclabs.net
generation: 2
resourceVersion: "372437851"
uid: 3810c0ab-42c3-4945-9869-4e9fda78142f

== Conditions ==========================
  - VMIsRunning=True (VMIsRunning) 1003h5m28s
  - Ready=True (Ready) 1003h5m28s

== Status ==============================
attachedDisks:
  - device: vda
    name: my-boot-disk
networking:
  privateIPv4Address: 10.0.0.29
  publicIPv4Address: 185.222.1.1
virtualMachineStatus: Running

== Spec ================================
diskRefs:
  - bootFrom: true
    name: my-boot-disk
networking:
  publicIPv4Address:
    static:
      publicIPRef: my-ip
  securityGroups:
    securityGroupMemberships:
      - name: default-sto-1
      - name: allow-https
osSettings:
  ssh:
    authorizedKeys:
      - value: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN6WmLBGCociGnjW53RmLAvJ6CRBNUF2GD9U1vMSTWLE
running: true
vmVirtualResourcesRef:
  vmVirtualResourcesRefName: general.xl