Enabling or Disabling Secure Boot

To enable secure boot, you need to create a virtual machine (VM) from an OUTSCALE machine image (OMI) compatible with UEFI.

You can enable or disable secure boot at the VM creation or after.

After creation, you need to stop/start the VM as the action is applied at the next VM start. Multiple requests are not queued. Only the last action requested before starting the VM is applied. For more information, see About Secure Boot and About Boot Modes.

Enabling or disabling secure boot is possible through the OUTSCALE API only.

Enabling Secure Boot

Enabling at VM Creation

  1. Create an OMI compatible with UEFI. For more information, see Creating an OMI or use the following command:

    Request sample
    osc-cli api CreateImage --profile "default" \
        --ImageName "create-uefi-image-example" \
        --VmId "i-12345678" \
        --BootModes '["uefi"]' \
        --NoReboot True
  2. Create a VM from the previously created OMI and enable secure boot.
    You can use the following example with a minimal syntax or customize the VM depending on your needs. For more information, see Creating VMs.

    Request sample
    $ osc-cli api CreateVms \
        --profile "default" \
        --ImageId "ami-12345678" \
        --ActionsOnNextBoot '{"Secureboot": "enable"}'

Enabling After VM Creation

  1. Enable secure boot on the desired VM with the following command:

    Request sample
    $ osc-cli api UpdateVm \
        --profile "default" \
        --VmId "i-12345678" \
        --ActionsOnNextBoot '{"Secureboot": "enable"}'
  2. Stop and start the VM to apply the action. For more information, see Stopping and Starting VMs.

Disabling Secure Boot

Disable secure boot on the desired VM with the following command:

Request sample
$ osc-cli api UpdateVm \
    --profile "default" \
    --VmId "i-12345678" \
    --ActionsOnNextBoot '{"Secureboot": "disable"}'

Related Pages