# virt.instance.create

Create a new virtualized instance.

This method is a job.

Type: object

##

Type: array
No Additional Items

#### Tuple Validation

##### Parameter 1: virt_instance_create

#### virt_instance_create

Type: object

VirtInstanceCreateArgs parameters.

No Additional Properties

##

#### Name

Type: string

Must be at least `1` characters long

Must be at most `200` characters long

##

#### Iso Volume

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Source Type

Type: const Default: "IMAGE"
Specific value: `"IMAGE"`

##

#### Storage Pool

Default: null

Storage pool under which to allocate root filesystem. Must be one of the pools
listed in virt.global.config output under "storage_pools". If None (default) then the pool
specified in the global configuration will be used.

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Image

Type: string

Must be at least `1` characters long

Must be at most `200` characters long

##

#### Remote

Type: const Default: "LINUX_CONTAINERS"
Specific value: `"LINUX_CONTAINERS"`

##

#### Instance Type

Type: const Default: "CONTAINER"
Specific value: `"CONTAINER"`

##

#### Environment

Default: null

## Any of

Type: object

##

Each additional property must conform to the following schema

Type: string
Type: null

##

#### Autostart

Default: true

## Any of

Type: boolean
Type: null

##

#### Cpu

Default: null

## Any of

Type: string
Type: null

##

#### Devices

Default: null

## Any of

Type: array
No Additional Items

##### Each item of this array must be:

## One of

#### Disk

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"DISK"`

##

#### Source

Default: null

For CONTAINER instances, this would be a valid pool path. For VM instances, it
can be a valid zvol path or an incus storage volume name

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Destination

Default: null

## Any of

Type: string
Type: null

##

#### Boot Priority

Default: null

## Any of

Type: integer

Value must be greater or equal to `0`

Type: null

##

#### Io Bus

Type: enum (of null or string) Default: null

##### Must be one of:

- "NVME"
- "VIRTIO-BLK"
- "VIRTIO-SCSI"
- null

##

#### Storage Pool

Default: null

Storage pool in which the device is located. This must be one
of the storage pools listed in virt.global.config output.
If this is set to None during device creation, then the default storage
pool defined in virt.global.config will be used.

## Any of

Type: string

Must be at least `1` characters long

Type: null

#### GPU

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"GPU"`

##

#### Gpu Type

Type: enum (of string)

##### Must be one of:

- "PHYSICAL"
- "MDEV"
- "MIG"
- "SRIOV"

##

#### Id

Default: null

## Any of

Type: string
Type: null

##

#### Gid

Default: null

## Any of

Type: integer

Value must be greater or equal to `0` and lesser or equal to `90000000`

Type: null

##

#### Uid

Default: null

## Any of

Type: integer

Value must be greater or equal to `0` and lesser or equal to `90000000`

Type: null

##

#### Mode

Default: null

## Any of

Type: string
Type: null

##

#### Mdev

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Mig Uuid

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Pci

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Productid

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Vendorid

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

#### Proxy

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"PROXY"`

##

#### Source Proto

Type: enum (of string)

##### Must be one of:

- "UDP"
- "TCP"

##

#### Source Port

Type: integer

Value must be greater or equal to `1` and lesser or equal to `65535`

##

#### Dest Proto

Type: enum (of string)

##### Must be one of:

- "UDP"
- "TCP"

##

#### Dest Port

Type: integer

Value must be greater or equal to `1` and lesser or equal to `65535`

#### TPM

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"TPM"`

##

#### Path

Default: null

## Any of

Type: string
Type: null

##

#### Pathrm

Default: null

## Any of

Type: string
Type: null

#### USB

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"USB"`

##

#### Bus

Default: null

## Any of

Type: integer
Type: null

##

#### Dev

Default: null

## Any of

Type: integer
Type: null

##

#### Product Id

Default: null

## Any of

Type: string
Type: null

##

#### Vendor Id

Default: null

## Any of

Type: string
Type: null

#### NIC

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"NIC"`

##

#### Network

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Nic Type

Default: null

## Any of

Type: enum (of string)

##### Must be one of:

- "BRIDGED"
- "MACVLAN"

Type: null

##

#### Parent

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

#### PCI

Type: object
No Additional Properties

##

#### Name

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Description

Default: null

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Readonly

Type: boolean Default: false

##

#### Dev Type

Type: const
Specific value: `"PCI"`

##

#### Address

Type: string

Must be at least `1` characters long

Type: null

##

#### Memory

Default: null

## Any of

Type: integer
Type: null

##

#### VirtInstanceEntry

Type: object
No Additional Properties

##

#### Id

Type: string

##

#### Name

Type: string

Must be at least `1` characters long

Must be at most `200` characters long

##

#### Type

Type: enum (of string) Default: "CONTAINER"

##### Must be one of:

- "CONTAINER"
- "VM"

##

#### Status

Type: enum (of string)

##### Must be one of:

- "RUNNING"
- "STOPPED"
- "UNKNOWN"
- "ERROR"
- "FROZEN"
- "STARTING"
- "STOPPING"
- "FREEZING"
- "THAWED"
- "ABORTING"

##

#### Cpu

## Any of

Type: string
Type: null

##

#### Memory

## Any of

Type: integer
Type: null

##

#### Autostart

Type: boolean

##

#### Environment

Type: object

##

Each additional property must conform to the following schema

Type: string

##

#### Aliases

Type: array of object
No Additional Items

##### Each item of this array must be:

#### VirtInstanceAlias

Type: object
No Additional Properties

##

#### Type

Type: enum (of string)

##### Must be one of:

- "INET"
- "INET6"

##

#### Address

Type: string

Must be at least `1` characters long

##

#### Netmask

## Any of

Type: integer
Type: null

##

#### Image

Type: object
No Additional Properties

##

#### Architecture

## Any of

Type: string
Type: null

##

#### Description

## Any of

Type: string
Type: null

##

#### Os

## Any of

Type: string
Type: null

##

#### Release

## Any of

Type: string
Type: null

##

#### Serial

## Any of

Type: string
Type: null

##

#### Type

## Any of

Type: string
Type: null

##

#### Variant

## Any of

Type: string
Type: null

##

#### Secureboot

## Any of

Type: boolean
Type: null

##

## Any of

#### UserNsIdmap

Type: object
No Additional Properties

##

#### IdmapUserNsEntry

Type: object
No Additional Properties

##

#### Hostid

Type: integer

##

#### Maprange

Type: integer

##

#### Nsid

Type: integer

##

#### IdmapUserNsEntry

Type: object
No Additional Properties

##

#### Hostid

Type: integer

##

#### Maprange

Type: integer

##

#### Nsid

Type: integer
Type: null

##

#### Raw

## Any of

Type: object
Type: null

##

#### Vnc Enabled

Type: boolean

##

#### Vnc Port

## Any of

Type: integer
Type: null

##

#### Vnc Password

## Any of

Type: string

Must be at least `1` characters long

Type: null

##

#### Secure Boot

## Any of

Type: boolean
Type: null

##

#### Root Disk Size

## Any of

Type: integer
Type: null

##

#### Root Disk Io Bus

Type: enum (of null or string)

##### Must be one of:

- "NVME"
- "VIRTIO-BLK"
- "VIRTIO-SCSI"
- null

##

#### Storage Pool

Type: string

Storage pool in which the root of the instance is located.

Must be at least `1` characters long

Required roles: VIRT_INSTANCE_WRITE