Documentation ¶
Index ¶
- type Client
- func (c *Client) CloneVmClone(ctx context.Context, req *CloneVmCloneRequest) (*CloneVmCloneResponse, error)
- func (c *Client) Create(ctx context.Context, req *CreateRequest) (*CreateResponse, error)
- func (c *Client) Delete(ctx context.Context, req *DeleteRequest) (*DeleteResponse, error)
- func (c *Client) Find(ctx context.Context, req *FindRequest) (*FindResponse, error)
- func (c *Client) Index(ctx context.Context, req *IndexRequest) (*IndexResponse, error)
- func (c *Client) MigrateVmMigrate(ctx context.Context, req *MigrateVmMigrateRequest) (*MigrateVmMigrateResponse, error)
- func (c *Client) MigrateVmPreconditionMigrate(ctx context.Context, req *MigrateVmPreconditionMigrateRequest) (*MigrateVmPreconditionMigrateResponse, error)
- func (c *Client) Monitor(ctx context.Context, req *MonitorRequest) (*MonitorResponse, error)
- func (c *Client) MoveVmDiskMoveDisk(ctx context.Context, req *MoveVmDiskMoveDiskRequest) (*MoveVmDiskMoveDiskResponse, error)
- func (c *Client) Mtunnel(ctx context.Context, req *MtunnelRequest) (*MtunnelResponse, error)
- func (c *Client) Mtunnelwebsocket(ctx context.Context, req *MtunnelwebsocketRequest) (*MtunnelwebsocketResponse, error)
- func (c *Client) RemoteMigrateVmRemoteMigrate(ctx context.Context, req *RemoteMigrateVmRemoteMigrateRequest) (*RemoteMigrateVmRemoteMigrateResponse, error)
- func (c *Client) ResizeVmResize(ctx context.Context, req *ResizeVmResizeRequest) (*ResizeVmResizeResponse, error)
- func (c *Client) Rrd(ctx context.Context, req *RrdRequest) (*RrdResponse, error)
- func (c *Client) Rrddata(ctx context.Context, req *RrddataRequest) (*RrddataResponse, error)
- func (c *Client) Spiceproxy(ctx context.Context, req *SpiceproxyRequest) (*SpiceproxyResponse, error)
- func (c *Client) Template(ctx context.Context, req *TemplateRequest) (*TemplateResponse, error)
- func (c *Client) Termproxy(ctx context.Context, req *TermproxyRequest) (*TermproxyResponse, error)
- func (c *Client) Unlink(ctx context.Context, req *UnlinkRequest) (*UnlinkResponse, error)
- func (c *Client) UpdateVmAsyncConfig(ctx context.Context, req *UpdateVmAsyncConfigRequest) (*UpdateVmAsyncConfigResponse, error)
- func (c *Client) UpdateVmConfig(ctx context.Context, req *UpdateVmConfigRequest) (*UpdateVmConfigResponse, error)
- func (c *Client) VmConfig(ctx context.Context, req *VmConfigRequest) (*VmConfigResponse, error)
- func (c *Client) VmFeature(ctx context.Context, req *VmFeatureRequest) (*VmFeatureResponse, error)
- func (c *Client) VmPending(ctx context.Context, req *VmPendingRequest) (*VmPendingResponse, error)
- func (c *Client) VmSendkey(ctx context.Context, req *VmSendkeyRequest) (*VmSendkeyResponse, error)
- func (c *Client) Vncproxy(ctx context.Context, req *VncproxyRequest) (*VncproxyResponse, error)
- func (c *Client) Vncwebsocket(ctx context.Context, req *VncwebsocketRequest) (*VncwebsocketResponse, error)
- type CloneVmCloneRequest
- type CloneVmCloneResponse
- type CreateRequest
- type CreateResponse
- type DeleteRequest
- type DeleteResponse
- type FindRequest
- type FindResponse
- type HTTPClient
- type IndexRequest
- type IndexResponse
- type MigrateVmMigrateRequest
- type MigrateVmMigrateResponse
- type MigrateVmPreconditionMigrateRequest
- type MigrateVmPreconditionMigrateResponse
- type MonitorRequest
- type MonitorResponse
- type MoveVmDiskMoveDiskRequest
- type MoveVmDiskMoveDiskResponse
- type MtunnelRequest
- type MtunnelResponse
- type MtunnelwebsocketRequest
- type MtunnelwebsocketResponse
- type RemoteMigrateVmRemoteMigrateRequest
- type RemoteMigrateVmRemoteMigrateResponse
- type ResizeVmResizeRequest
- type ResizeVmResizeResponse
- type RrdRequest
- type RrdResponse
- type RrddataRequest
- type RrddataResponse
- type SpiceproxyRequest
- type SpiceproxyResponse
- type TemplateRequest
- type TemplateResponse
- type TermproxyRequest
- type TermproxyResponse
- type UnlinkRequest
- type UnlinkResponse
- type UpdateVmAsyncConfigRequest
- type UpdateVmAsyncConfigResponse
- type UpdateVmConfigRequest
- type UpdateVmConfigResponse
- type VmConfigRequest
- type VmConfigResponse
- type VmFeatureRequest
- type VmFeatureResponse
- type VmPendingRequest
- type VmPendingResponse
- type VmSendkeyRequest
- type VmSendkeyResponse
- type VncproxyRequest
- type VncproxyResponse
- type VncwebsocketRequest
- type VncwebsocketResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func New ¶
func New(c HTTPClient) *Client
func (*Client) CloneVmClone ¶
func (c *Client) CloneVmClone(ctx context.Context, req *CloneVmCloneRequest) (*CloneVmCloneResponse, error)
CloneVmClone Create a copy of virtual machine/template.
func (*Client) Create ¶
func (c *Client) Create(ctx context.Context, req *CreateRequest) (*CreateResponse, error)
Create Create or restore a virtual machine.
func (*Client) Delete ¶
func (c *Client) Delete(ctx context.Context, req *DeleteRequest) (*DeleteResponse, error)
Delete Destroy the VM and all used/owned volumes. Removes any VM specific permissions and firewall rules
func (*Client) Find ¶
func (c *Client) Find(ctx context.Context, req *FindRequest) (*FindResponse, error)
Find Directory index
func (*Client) Index ¶
func (c *Client) Index(ctx context.Context, req *IndexRequest) (*IndexResponse, error)
Index Virtual machine index (per node).
func (*Client) MigrateVmMigrate ¶
func (c *Client) MigrateVmMigrate(ctx context.Context, req *MigrateVmMigrateRequest) (*MigrateVmMigrateResponse, error)
MigrateVmMigrate Migrate virtual machine. Creates a new migration task.
func (*Client) MigrateVmPreconditionMigrate ¶
func (c *Client) MigrateVmPreconditionMigrate(ctx context.Context, req *MigrateVmPreconditionMigrateRequest) (*MigrateVmPreconditionMigrateResponse, error)
MigrateVmPreconditionMigrate Get preconditions for migration.
func (*Client) Monitor ¶
func (c *Client) Monitor(ctx context.Context, req *MonitorRequest) (*MonitorResponse, error)
Monitor Execute Qemu monitor commands.
func (*Client) MoveVmDiskMoveDisk ¶
func (c *Client) MoveVmDiskMoveDisk(ctx context.Context, req *MoveVmDiskMoveDiskRequest) (*MoveVmDiskMoveDiskResponse, error)
MoveVmDiskMoveDisk Move volume to different storage or to a different VM.
func (*Client) Mtunnel ¶
func (c *Client) Mtunnel(ctx context.Context, req *MtunnelRequest) (*MtunnelResponse, error)
Mtunnel Migration tunnel endpoint - only for internal use by VM migration.
func (*Client) Mtunnelwebsocket ¶
func (c *Client) Mtunnelwebsocket(ctx context.Context, req *MtunnelwebsocketRequest) (*MtunnelwebsocketResponse, error)
Mtunnelwebsocket Migration tunnel endpoint for websocket upgrade - only for internal use by VM migration.
func (*Client) RemoteMigrateVmRemoteMigrate ¶
func (c *Client) RemoteMigrateVmRemoteMigrate(ctx context.Context, req *RemoteMigrateVmRemoteMigrateRequest) (*RemoteMigrateVmRemoteMigrateResponse, error)
RemoteMigrateVmRemoteMigrate Migrate virtual machine to a remote cluster. Creates a new migration task. EXPERIMENTAL feature!
func (*Client) ResizeVmResize ¶
func (c *Client) ResizeVmResize(ctx context.Context, req *ResizeVmResizeRequest) (*ResizeVmResizeResponse, error)
ResizeVmResize Extend volume size.
func (*Client) Rrd ¶
func (c *Client) Rrd(ctx context.Context, req *RrdRequest) (*RrdResponse, error)
Rrd Read VM RRD statistics (returns PNG)
func (*Client) Rrddata ¶
func (c *Client) Rrddata(ctx context.Context, req *RrddataRequest) (*RrddataResponse, error)
Rrddata Read VM RRD statistics
func (*Client) Spiceproxy ¶
func (c *Client) Spiceproxy(ctx context.Context, req *SpiceproxyRequest) (*SpiceproxyResponse, error)
Spiceproxy Returns a SPICE configuration to connect to the VM.
func (*Client) Template ¶
func (c *Client) Template(ctx context.Context, req *TemplateRequest) (*TemplateResponse, error)
Template Create a Template.
func (*Client) Termproxy ¶
func (c *Client) Termproxy(ctx context.Context, req *TermproxyRequest) (*TermproxyResponse, error)
Termproxy Creates a TCP proxy connections.
func (*Client) Unlink ¶
func (c *Client) Unlink(ctx context.Context, req *UnlinkRequest) (*UnlinkResponse, error)
Unlink Unlink/delete disk images.
func (*Client) UpdateVmAsyncConfig ¶
func (c *Client) UpdateVmAsyncConfig(ctx context.Context, req *UpdateVmAsyncConfigRequest) (*UpdateVmAsyncConfigResponse, error)
UpdateVmAsyncConfig Set virtual machine options (asynchrounous API).
func (*Client) UpdateVmConfig ¶
func (c *Client) UpdateVmConfig(ctx context.Context, req *UpdateVmConfigRequest) (*UpdateVmConfigResponse, error)
UpdateVmConfig Set virtual machine options (synchrounous API) - You should consider using the POST method instead for any actions involving hotplug or storage allocation.
func (*Client) VmConfig ¶
func (c *Client) VmConfig(ctx context.Context, req *VmConfigRequest) (*VmConfigResponse, error)
VmConfig Get the virtual machine configuration with pending configuration changes applied. Set the 'current' parameter to get the current configuration instead.
func (*Client) VmFeature ¶
func (c *Client) VmFeature(ctx context.Context, req *VmFeatureRequest) (*VmFeatureResponse, error)
VmFeature Check if feature for virtual machine is available.
func (*Client) VmPending ¶
func (c *Client) VmPending(ctx context.Context, req *VmPendingRequest) (*VmPendingResponse, error)
VmPending Get the virtual machine configuration with both current and pending values.
func (*Client) VmSendkey ¶
func (c *Client) VmSendkey(ctx context.Context, req *VmSendkeyRequest) (*VmSendkeyResponse, error)
VmSendkey Send key event to virtual machine.
func (*Client) Vncproxy ¶
func (c *Client) Vncproxy(ctx context.Context, req *VncproxyRequest) (*VncproxyResponse, error)
Vncproxy Creates a TCP VNC proxy connections.
func (*Client) Vncwebsocket ¶
func (c *Client) Vncwebsocket(ctx context.Context, req *VncwebsocketRequest) (*VncwebsocketResponse, error)
Vncwebsocket Opens a weksocket for VNC traffic.
type CloneVmCloneRequest ¶
type CloneVmCloneRequest struct { Newid int `url:"newid",json:"newid"` // VMID for the clone. Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Bwlimit *int `url:"bwlimit,omitempty",json:"bwlimit,omitempty"` // Override I/O bandwidth limit (in KiB/s). Description *string `url:"description,omitempty",json:"description,omitempty"` // Description for the new VM. Format *string `url:"format,omitempty",json:"format,omitempty"` // Target format for file storage. Only valid for full clone. Full *bool `url:"full,omitempty",json:"full,omitempty"` // Create a full copy of all disks. This is always done when you clone a normal VM. For VM templates, we try to create a linked clone by default. Name *string `url:"name,omitempty",json:"name,omitempty"` // Set a name for the new VM. Pool *string `url:"pool,omitempty",json:"pool,omitempty"` // Add the new VM to the specified pool. Snapname *string `url:"snapname,omitempty",json:"snapname,omitempty"` // The name of the snapshot. Storage *string `url:"storage,omitempty",json:"storage,omitempty"` // Target storage for full clone. Target *string `url:"target,omitempty",json:"target,omitempty"` // Target node. Only allowed if the original VM is on shared storage. }
type CloneVmCloneResponse ¶
type CloneVmCloneResponse string
type CreateRequest ¶
type CreateRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Acpi *bool `url:"acpi,omitempty",json:"acpi,omitempty"` // Enable/disable ACPI. Affinity *string `url:"affinity,omitempty",json:"affinity,omitempty"` // List of host cores used to execute guest processes, for example: 0,5,8-11 Agent *string `url:"agent,omitempty",json:"agent,omitempty"` // Enable/disable communication with the Qemu Guest Agent and its properties. Arch *string `url:"arch,omitempty",json:"arch,omitempty"` // Virtual processor architecture. Defaults to the host. Archive *string `url:"archive,omitempty",json:"archive,omitempty"` // The backup archive. Either the file system path to a .tar or .vma file (use '-' to pipe data from stdin) or a proxmox storage backup volume identifier. Args *string `url:"args,omitempty",json:"args,omitempty"` // Arbitrary arguments passed to kvm. Audio0 *string `url:"audio0,omitempty",json:"audio0,omitempty"` // Configure a audio device, useful in combination with QXL/Spice. Autostart *bool `url:"autostart,omitempty",json:"autostart,omitempty"` // Automatic restart after crash (currently ignored). Balloon *int `url:"balloon,omitempty",json:"balloon,omitempty"` // Amount of target RAM for the VM in MB. Using zero disables the ballon driver. Bios *string `url:"bios,omitempty",json:"bios,omitempty"` // Select BIOS implementation. Boot *string `url:"boot,omitempty",json:"boot,omitempty"` // Specify guest boot order. Use the 'order=' sub-property as usage with no key or 'legacy=' is deprecated. Bootdisk *string `url:"bootdisk,omitempty",json:"bootdisk,omitempty"` // Enable booting from specified disk. Deprecated: Use 'boot: order=foo;bar' instead. Bwlimit *int `url:"bwlimit,omitempty",json:"bwlimit,omitempty"` // Override I/O bandwidth limit (in KiB/s). Cdrom *string `url:"cdrom,omitempty",json:"cdrom,omitempty"` // This is an alias for option -ide2 Cicustom *string `url:"cicustom,omitempty",json:"cicustom,omitempty"` // cloud-init: Specify custom files to replace the automatically generated ones at start. Cipassword *string `url:"cipassword,omitempty",json:"cipassword,omitempty"` // cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords. Citype *string `url:"citype,omitempty",json:"citype,omitempty"` // Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows. Ciuser *string `url:"ciuser,omitempty",json:"ciuser,omitempty"` // cloud-init: User name to change ssh keys and password for instead of the image's configured default user. Cores *int `url:"cores,omitempty",json:"cores,omitempty"` // The number of cores per socket. Cpu *string `url:"cpu,omitempty",json:"cpu,omitempty"` // Emulated CPU type. Cpulimit *float64 `url:"cpulimit,omitempty",json:"cpulimit,omitempty"` // Limit of CPU usage. Cpuunits *int `url:"cpuunits,omitempty",json:"cpuunits,omitempty"` // CPU weight for a VM, will be clamped to [1, 10000] in cgroup v2. Description *string `url:"description,omitempty",json:"description,omitempty"` // Description for the VM. Shown in the web-interface VM's summary. This is saved as comment inside the configuration file. Efidisk0 *string `url:"efidisk0,omitempty",json:"efidisk0,omitempty"` // Configure a Disk for storing EFI vars. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and that the default EFI vars are copied to the volume instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Force *bool `url:"force,omitempty",json:"force,omitempty"` // Allow to overwrite existing VM. Freeze *bool `url:"freeze,omitempty",json:"freeze,omitempty"` // Freeze CPU at startup (use 'c' monitor command to start execution). Hookscript *string `url:"hookscript,omitempty",json:"hookscript,omitempty"` // Script that will be executed during various steps in the vms lifetime. Hostpcin *string `url:"hostpci[n],omitempty",json:"hostpci[n],omitempty"` // Map host PCI devices into guest. Hotplug *string `url:"hotplug,omitempty",json:"hotplug,omitempty"` // Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory', 'usb' and 'cloudinit'. Use '0' to disable hotplug completely. Using '1' as value is an alias for the default `network,disk,usb`. USB hotplugging is possible for guests with machine version >= 7.1 and ostype l26 or windows > 7. Hugepages *string `url:"hugepages,omitempty",json:"hugepages,omitempty"` // Enable/disable hugepages memory. Iden *string `url:"ide[n],omitempty",json:"ide[n],omitempty"` // Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Ipconfign *string `url:"ipconfig[n],omitempty",json:"ipconfig[n],omitempty"` // cloud-init: Specify IP addresses and gateways for the corresponding interface.IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicitgateway should be provided.For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requirescloud-init 19.4 or newer.If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to usingdhcp on IPv4. Ivshmem *string `url:"ivshmem,omitempty",json:"ivshmem,omitempty"` // Inter-VM shared memory. Useful for direct communication between VMs, or to the host. Keephugepages *bool `url:"keephugepages,omitempty",json:"keephugepages,omitempty"` // Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. Keyboard *string `url:"keyboard,omitempty",json:"keyboard,omitempty"` // Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. Kvm *bool `url:"kvm,omitempty",json:"kvm,omitempty"` // Enable/disable KVM hardware virtualization. LiveRestore *bool `url:"live-restore,omitempty",json:"live-restore,omitempty"` // Start the VM immediately from the backup and restore in background. PBS only. Localtime *bool `url:"localtime,omitempty",json:"localtime,omitempty"` // Set the real time clock (RTC) to local time. This is enabled by default if the `ostype` indicates a Microsoft Windows OS. Lock *string `url:"lock,omitempty",json:"lock,omitempty"` // Lock/unlock the VM. Machine *string `url:"machine,omitempty",json:"machine,omitempty"` // Specifies the Qemu machine type. Memory *int `url:"memory,omitempty",json:"memory,omitempty"` // Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device. MigrateDowntime *float64 `url:"migrate_downtime,omitempty",json:"migrate_downtime,omitempty"` // Set maximum tolerated downtime (in seconds) for migrations. MigrateSpeed *int `url:"migrate_speed,omitempty",json:"migrate_speed,omitempty"` // Set maximum speed (in MB/s) for migrations. Value 0 is no limit. Name *string `url:"name,omitempty",json:"name,omitempty"` // Set a name for the VM. Only used on the configuration web interface. Nameserver *string `url:"nameserver,omitempty",json:"nameserver,omitempty"` // cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Netn *string `url:"net[n],omitempty",json:"net[n],omitempty"` // Specify network devices. Numa *bool `url:"numa,omitempty",json:"numa,omitempty"` // Enable/disable NUMA. Numan *string `url:"numa[n],omitempty",json:"numa[n],omitempty"` // NUMA topology. Onboot *bool `url:"onboot,omitempty",json:"onboot,omitempty"` // Specifies whether a VM will be started during system bootup. Ostype *string `url:"ostype,omitempty",json:"ostype,omitempty"` // Specify guest operating system. Paralleln *string `url:"parallel[n],omitempty",json:"parallel[n],omitempty"` // Map host parallel devices (n is 0 to 2). Pool *string `url:"pool,omitempty",json:"pool,omitempty"` // Add the VM to the specified pool. Protection *bool `url:"protection,omitempty",json:"protection,omitempty"` // Sets the protection flag of the VM. This will disable the remove VM and remove disk operations. Reboot *bool `url:"reboot,omitempty",json:"reboot,omitempty"` // Allow reboot. If set to '0' the VM exit on reboot. Rng0 *string `url:"rng0,omitempty",json:"rng0,omitempty"` // Configure a VirtIO-based Random Number Generator. Satan *string `url:"sata[n],omitempty",json:"sata[n],omitempty"` // Use volume as SATA hard disk or CD-ROM (n is 0 to 5). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Scsihw *string `url:"scsihw,omitempty",json:"scsihw,omitempty"` // SCSI controller model Scsin *string `url:"scsi[n],omitempty",json:"scsi[n],omitempty"` // Use volume as SCSI hard disk or CD-ROM (n is 0 to 30). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Searchdomain *string `url:"searchdomain,omitempty",json:"searchdomain,omitempty"` // cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Serialn *string `url:"serial[n],omitempty",json:"serial[n],omitempty"` // Create a serial device inside the VM (n is 0 to 3) Smbios1 *string `url:"smbios1,omitempty",json:"smbios1,omitempty"` // Specify SMBIOS type 1 fields. Smp *int `url:"smp,omitempty",json:"smp,omitempty"` // The number of CPUs. Please use option -sockets instead. Sockets *int `url:"sockets,omitempty",json:"sockets,omitempty"` // The number of CPU sockets. SpiceEnhancements *string `url:"spice_enhancements,omitempty",json:"spice_enhancements,omitempty"` // Configure additional enhancements for SPICE. Sshkeys *string `url:"sshkeys,omitempty",json:"sshkeys,omitempty"` // cloud-init: Setup public SSH keys (one key per line, OpenSSH format). Start *bool `url:"start,omitempty",json:"start,omitempty"` // Start VM after it was created successfully. Startdate *string `url:"startdate,omitempty",json:"startdate,omitempty"` // Set the initial date of the real time clock. Valid format for date are:'now' or '2006-06-17T16:01:21' or '2006-06-17'. Startup *string `url:"startup,omitempty",json:"startup,omitempty"` // Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped. Storage *string `url:"storage,omitempty",json:"storage,omitempty"` // Default storage. Tablet *bool `url:"tablet,omitempty",json:"tablet,omitempty"` // Enable/disable the USB tablet device. Tags *string `url:"tags,omitempty",json:"tags,omitempty"` // Tags of the VM. This is only meta information. Tdf *bool `url:"tdf,omitempty",json:"tdf,omitempty"` // Enable/disable time drift fix. Template *bool `url:"template,omitempty",json:"template,omitempty"` // Enable/disable Template. Tpmstate0 *string `url:"tpmstate0,omitempty",json:"tpmstate0,omitempty"` // Configure a Disk for storing TPM state. The format is fixed to 'raw'. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and 4 MiB will be used instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Unique *bool `url:"unique,omitempty",json:"unique,omitempty"` // Assign a unique random ethernet address. Unusedn *string `url:"unused[n],omitempty",json:"unused[n],omitempty"` // Reference to unused volumes. This is used internally, and should not be modified manually. Usbn *string `url:"usb[n],omitempty",json:"usb[n],omitempty"` // Configure an USB device (n is 0 to 4, for machine version >= 7.1 and ostype l26 or windows > 7, n can be up to 14). Vcpus *int `url:"vcpus,omitempty",json:"vcpus,omitempty"` // Number of hotplugged vcpus. Vga *string `url:"vga,omitempty",json:"vga,omitempty"` // Configure the VGA hardware. Virtion *string `url:"virtio[n],omitempty",json:"virtio[n],omitempty"` // Use volume as VIRTIO hard disk (n is 0 to 15). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Vmgenid *string `url:"vmgenid,omitempty",json:"vmgenid,omitempty"` // Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly. Vmstatestorage *string `url:"vmstatestorage,omitempty",json:"vmstatestorage,omitempty"` // Default storage for VM state volumes/files. Watchdog *string `url:"watchdog,omitempty",json:"watchdog,omitempty"` // Create a virtual hardware watchdog device. }
type CreateResponse ¶
type CreateResponse string
type DeleteRequest ¶
type DeleteRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional DestroyUnreferencedDisks *bool `url:"destroy-unreferenced-disks,omitempty",json:"destroy-unreferenced-disks,omitempty"` // If set, destroy additionally all disks not referenced in the config but with a matching VMID from all enabled storages. Purge *bool `url:"purge,omitempty",json:"purge,omitempty"` // Remove VMID from configurations, like backup & replication jobs and HA. Skiplock *bool `url:"skiplock,omitempty",json:"skiplock,omitempty"` // Ignore locks - only root is allowed to use this option. }
type DeleteResponse ¶
type DeleteResponse string
type FindRequest ¶
type FindResponse ¶
type FindResponse []*struct { Subdir string `url:"subdir",json:"subdir"` }
type HTTPClient ¶
type IndexRequest ¶
type IndexResponse ¶
type IndexResponse []*struct { Status string `url:"status",json:"status"` // Qemu process status. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Cpus *float64 `url:"cpus,omitempty",json:"cpus,omitempty"` // Maximum usable CPUs. Lock *string `url:"lock,omitempty",json:"lock,omitempty"` // The current config lock, if any. Maxdisk *int `url:"maxdisk,omitempty",json:"maxdisk,omitempty"` // Root disk size in bytes. Maxmem *int `url:"maxmem,omitempty",json:"maxmem,omitempty"` // Maximum memory in bytes. Name *string `url:"name,omitempty",json:"name,omitempty"` // VM name. Pid *int `url:"pid,omitempty",json:"pid,omitempty"` // PID of running qemu process. Qmpstatus *string `url:"qmpstatus,omitempty",json:"qmpstatus,omitempty"` // Qemu QMP agent status. RunningMachine *string `url:"running-machine,omitempty",json:"running-machine,omitempty"` // The currently running machine type (if running). RunningQemu *string `url:"running-qemu,omitempty",json:"running-qemu,omitempty"` // The currently running QEMU version (if running). Tags *string `url:"tags,omitempty",json:"tags,omitempty"` // The current configured tags, if any Uptime *int `url:"uptime,omitempty",json:"uptime,omitempty"` // Uptime. }
type MigrateVmMigrateRequest ¶
type MigrateVmMigrateRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Target string `url:"target",json:"target"` // Target node. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Bwlimit *int `url:"bwlimit,omitempty",json:"bwlimit,omitempty"` // Override I/O bandwidth limit (in KiB/s). Force *bool `url:"force,omitempty",json:"force,omitempty"` // Allow to migrate VMs which use local devices. Only root may use this option. MigrationNetwork *string `url:"migration_network,omitempty",json:"migration_network,omitempty"` // CIDR of the (sub) network that is used for migration. MigrationType *string `url:"migration_type,omitempty",json:"migration_type,omitempty"` // Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance. Online *bool `url:"online,omitempty",json:"online,omitempty"` // Use online/live migration if VM is running. Ignored if VM is stopped. Targetstorage *string `url:"targetstorage,omitempty",json:"targetstorage,omitempty"` // Mapping from source to target storages. Providing only a single storage ID maps all source storages to that storage. Providing the special value '1' will map each source storage to itself. WithLocalDisks *bool `url:"with-local-disks,omitempty",json:"with-local-disks,omitempty"` // Enable live storage migration for local disk }
type MigrateVmMigrateResponse ¶
type MigrateVmMigrateResponse string
type MigrateVmPreconditionMigrateResponse ¶
type MigrateVmPreconditionMigrateResponse struct { LocalDisks []*map[string]interface{} `url:"local_disks",json:"local_disks"` // List local disks including CD-Rom, unsused and not referenced disks LocalResources []*map[string]interface{} `url:"local_resources",json:"local_resources"` // List local resources e.g. pci, usb Running bool `url:"running",json:"running"` // The following parameters are optional AllowedNodes []*map[string]interface{} `url:"allowed_nodes,omitempty",json:"allowed_nodes,omitempty"` // List nodes allowed for offline migration, only passed if VM is offline NotAllowedNodes map[string]interface{} `url:"not_allowed_nodes,omitempty",json:"not_allowed_nodes,omitempty"` // List not allowed nodes with additional informations, only passed if VM is offline }
type MonitorRequest ¶
type MonitorResponse ¶
type MonitorResponse string
type MoveVmDiskMoveDiskRequest ¶
type MoveVmDiskMoveDiskRequest struct { Disk string `url:"disk",json:"disk"` // The disk you want to move. Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Bwlimit *int `url:"bwlimit,omitempty",json:"bwlimit,omitempty"` // Override I/O bandwidth limit (in KiB/s). Delete *bool `url:"delete,omitempty",json:"delete,omitempty"` // Delete the original disk after successful copy. By default the original disk is kept as unused disk. Digest *string `url:"digest,omitempty",json:"digest,omitempty"` // Prevent changes if current configuration file has different SHA1" ." digest. This can be used to prevent concurrent modifications. Format *string `url:"format,omitempty",json:"format,omitempty"` // Target Format. Storage *string `url:"storage,omitempty",json:"storage,omitempty"` // Target storage. TargetDigest *string `url:"target-digest,omitempty",json:"target-digest,omitempty"` // Prevent changes if the current config file of the target VM has a" ." different SHA1 digest. This can be used to detect concurrent modifications. TargetDisk *string `url:"target-disk,omitempty",json:"target-disk,omitempty"` // The config key the disk will be moved to on the target VM (for example, ide0 or scsi1). Default is the source disk key. TargetVmid *int `url:"target-vmid,omitempty",json:"target-vmid,omitempty"` // The (unique) ID of the VM. }
type MoveVmDiskMoveDiskResponse ¶
type MoveVmDiskMoveDiskResponse string
type MtunnelRequest ¶
type MtunnelRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Bridges *string `url:"bridges,omitempty",json:"bridges,omitempty"` // List of network bridges to check availability. Will be checked again for actually used bridges during migration. Storages *string `url:"storages,omitempty",json:"storages,omitempty"` // List of storages to check permission and availability. Will be checked again for all actually used storages during migration. }
type MtunnelResponse ¶
type MtunnelwebsocketRequest ¶
type MtunnelwebsocketRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Socket string `url:"socket",json:"socket"` // unix socket to forward to Ticket string `url:"ticket",json:"ticket"` // ticket return by initial 'mtunnel' API call, or retrieved via 'ticket' tunnel command Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. }
type MtunnelwebsocketResponse ¶
type MtunnelwebsocketResponse map[string]interface{}
type RemoteMigrateVmRemoteMigrateRequest ¶
type RemoteMigrateVmRemoteMigrateRequest struct { Node string `url:"node",json:"node"` // The cluster node name. TargetBridge string `url:"target-bridge",json:"target-bridge"` // Mapping from source to target bridges. Providing only a single bridge ID maps all source bridges to that bridge. Providing the special value '1' will map each source bridge to itself. TargetEndpoint string `url:"target-endpoint",json:"target-endpoint"` // Remote target endpoint TargetStorage string `url:"target-storage",json:"target-storage"` // Mapping from source to target storages. Providing only a single storage ID maps all source storages to that storage. Providing the special value '1' will map each source storage to itself. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Bwlimit *int `url:"bwlimit,omitempty",json:"bwlimit,omitempty"` // Override I/O bandwidth limit (in KiB/s). Delete *bool `url:"delete,omitempty",json:"delete,omitempty"` // Delete the original VM and related data after successful migration. By default the original VM is kept on the source cluster in a stopped state. Online *bool `url:"online,omitempty",json:"online,omitempty"` // Use online/live migration if VM is running. Ignored if VM is stopped. TargetVmid *int `url:"target-vmid,omitempty",json:"target-vmid,omitempty"` // The (unique) ID of the VM. }
type RemoteMigrateVmRemoteMigrateResponse ¶
type RemoteMigrateVmRemoteMigrateResponse string
type ResizeVmResizeRequest ¶
type ResizeVmResizeRequest struct { Disk string `url:"disk",json:"disk"` // The disk you want to resize. Node string `url:"node",json:"node"` // The cluster node name. Size string `url:"size",json:"size"` // The new size. With the `+` sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Digest *string `url:"digest,omitempty",json:"digest,omitempty"` // Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. Skiplock *bool `url:"skiplock,omitempty",json:"skiplock,omitempty"` // Ignore locks - only root is allowed to use this option. }
type ResizeVmResizeResponse ¶
type ResizeVmResizeResponse map[string]interface{}
type RrdRequest ¶
type RrdRequest struct { Ds string `url:"ds",json:"ds"` // The list of datasources you want to display. Node string `url:"node",json:"node"` // The cluster node name. Timeframe string `url:"timeframe",json:"timeframe"` // Specify the time frame you are interested in. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Cf *string `url:"cf,omitempty",json:"cf,omitempty"` // The RRD consolidation function }
type RrdResponse ¶
type RrdResponse struct {
Filename string `url:"filename",json:"filename"`
}
type RrddataRequest ¶
type RrddataRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Timeframe string `url:"timeframe",json:"timeframe"` // Specify the time frame you are interested in. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Cf *string `url:"cf,omitempty",json:"cf,omitempty"` // The RRD consolidation function }
type RrddataResponse ¶
type RrddataResponse []*map[string]interface{}
type SpiceproxyRequest ¶
type SpiceproxyRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Proxy *string `url:"proxy,omitempty",json:"proxy,omitempty"` // SPICE proxy server. This can be used by the client to specify the proxy server. All nodes in a cluster runs 'spiceproxy', so it is up to the client to choose one. By default, we return the node where the VM is currently running. As reasonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI). }
type SpiceproxyResponse ¶
type TemplateRequest ¶
type TemplateRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Disk *string `url:"disk,omitempty",json:"disk,omitempty"` // If you want to convert only 1 disk to base image. }
type TemplateResponse ¶
type TemplateResponse string
type TermproxyRequest ¶
type TermproxyRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Serial *string `url:"serial,omitempty",json:"serial,omitempty"` // opens a serial terminal (defaults to display) }
type TermproxyResponse ¶
type UnlinkRequest ¶
type UnlinkRequest struct { Idlist string `url:"idlist",json:"idlist"` // A list of disk IDs you want to delete. Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Force *bool `url:"force,omitempty",json:"force,omitempty"` // Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal. }
type UnlinkResponse ¶
type UnlinkResponse map[string]interface{}
type UpdateVmAsyncConfigRequest ¶
type UpdateVmAsyncConfigRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Acpi *bool `url:"acpi,omitempty",json:"acpi,omitempty"` // Enable/disable ACPI. Affinity *string `url:"affinity,omitempty",json:"affinity,omitempty"` // List of host cores used to execute guest processes, for example: 0,5,8-11 Agent *string `url:"agent,omitempty",json:"agent,omitempty"` // Enable/disable communication with the Qemu Guest Agent and its properties. Arch *string `url:"arch,omitempty",json:"arch,omitempty"` // Virtual processor architecture. Defaults to the host. Args *string `url:"args,omitempty",json:"args,omitempty"` // Arbitrary arguments passed to kvm. Audio0 *string `url:"audio0,omitempty",json:"audio0,omitempty"` // Configure a audio device, useful in combination with QXL/Spice. Autostart *bool `url:"autostart,omitempty",json:"autostart,omitempty"` // Automatic restart after crash (currently ignored). BackgroundDelay *int `url:"background_delay,omitempty",json:"background_delay,omitempty"` // Time to wait for the task to finish. We return 'null' if the task finish within that time. Balloon *int `url:"balloon,omitempty",json:"balloon,omitempty"` // Amount of target RAM for the VM in MB. Using zero disables the ballon driver. Bios *string `url:"bios,omitempty",json:"bios,omitempty"` // Select BIOS implementation. Boot *string `url:"boot,omitempty",json:"boot,omitempty"` // Specify guest boot order. Use the 'order=' sub-property as usage with no key or 'legacy=' is deprecated. Bootdisk *string `url:"bootdisk,omitempty",json:"bootdisk,omitempty"` // Enable booting from specified disk. Deprecated: Use 'boot: order=foo;bar' instead. Cdrom *string `url:"cdrom,omitempty",json:"cdrom,omitempty"` // This is an alias for option -ide2 Cicustom *string `url:"cicustom,omitempty",json:"cicustom,omitempty"` // cloud-init: Specify custom files to replace the automatically generated ones at start. Cipassword *string `url:"cipassword,omitempty",json:"cipassword,omitempty"` // cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords. Citype *string `url:"citype,omitempty",json:"citype,omitempty"` // Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows. Ciuser *string `url:"ciuser,omitempty",json:"ciuser,omitempty"` // cloud-init: User name to change ssh keys and password for instead of the image's configured default user. Cores *int `url:"cores,omitempty",json:"cores,omitempty"` // The number of cores per socket. Cpu *string `url:"cpu,omitempty",json:"cpu,omitempty"` // Emulated CPU type. Cpulimit *float64 `url:"cpulimit,omitempty",json:"cpulimit,omitempty"` // Limit of CPU usage. Cpuunits *int `url:"cpuunits,omitempty",json:"cpuunits,omitempty"` // CPU weight for a VM, will be clamped to [1, 10000] in cgroup v2. Delete *string `url:"delete,omitempty",json:"delete,omitempty"` // A list of settings you want to delete. Description *string `url:"description,omitempty",json:"description,omitempty"` // Description for the VM. Shown in the web-interface VM's summary. This is saved as comment inside the configuration file. Digest *string `url:"digest,omitempty",json:"digest,omitempty"` // Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. Efidisk0 *string `url:"efidisk0,omitempty",json:"efidisk0,omitempty"` // Configure a Disk for storing EFI vars. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and that the default EFI vars are copied to the volume instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Force *bool `url:"force,omitempty",json:"force,omitempty"` // Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal. Freeze *bool `url:"freeze,omitempty",json:"freeze,omitempty"` // Freeze CPU at startup (use 'c' monitor command to start execution). Hookscript *string `url:"hookscript,omitempty",json:"hookscript,omitempty"` // Script that will be executed during various steps in the vms lifetime. Hostpcin *string `url:"hostpci[n],omitempty",json:"hostpci[n],omitempty"` // Map host PCI devices into guest. Hotplug *string `url:"hotplug,omitempty",json:"hotplug,omitempty"` // Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory', 'usb' and 'cloudinit'. Use '0' to disable hotplug completely. Using '1' as value is an alias for the default `network,disk,usb`. USB hotplugging is possible for guests with machine version >= 7.1 and ostype l26 or windows > 7. Hugepages *string `url:"hugepages,omitempty",json:"hugepages,omitempty"` // Enable/disable hugepages memory. Iden *string `url:"ide[n],omitempty",json:"ide[n],omitempty"` // Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Ipconfign *string `url:"ipconfig[n],omitempty",json:"ipconfig[n],omitempty"` // cloud-init: Specify IP addresses and gateways for the corresponding interface.IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicitgateway should be provided.For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requirescloud-init 19.4 or newer.If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to usingdhcp on IPv4. Ivshmem *string `url:"ivshmem,omitempty",json:"ivshmem,omitempty"` // Inter-VM shared memory. Useful for direct communication between VMs, or to the host. Keephugepages *bool `url:"keephugepages,omitempty",json:"keephugepages,omitempty"` // Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. Keyboard *string `url:"keyboard,omitempty",json:"keyboard,omitempty"` // Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. Kvm *bool `url:"kvm,omitempty",json:"kvm,omitempty"` // Enable/disable KVM hardware virtualization. Localtime *bool `url:"localtime,omitempty",json:"localtime,omitempty"` // Set the real time clock (RTC) to local time. This is enabled by default if the `ostype` indicates a Microsoft Windows OS. Lock *string `url:"lock,omitempty",json:"lock,omitempty"` // Lock/unlock the VM. Machine *string `url:"machine,omitempty",json:"machine,omitempty"` // Specifies the Qemu machine type. Memory *int `url:"memory,omitempty",json:"memory,omitempty"` // Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device. MigrateDowntime *float64 `url:"migrate_downtime,omitempty",json:"migrate_downtime,omitempty"` // Set maximum tolerated downtime (in seconds) for migrations. MigrateSpeed *int `url:"migrate_speed,omitempty",json:"migrate_speed,omitempty"` // Set maximum speed (in MB/s) for migrations. Value 0 is no limit. Name *string `url:"name,omitempty",json:"name,omitempty"` // Set a name for the VM. Only used on the configuration web interface. Nameserver *string `url:"nameserver,omitempty",json:"nameserver,omitempty"` // cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Netn *string `url:"net[n],omitempty",json:"net[n],omitempty"` // Specify network devices. Numa *bool `url:"numa,omitempty",json:"numa,omitempty"` // Enable/disable NUMA. Numan *string `url:"numa[n],omitempty",json:"numa[n],omitempty"` // NUMA topology. Onboot *bool `url:"onboot,omitempty",json:"onboot,omitempty"` // Specifies whether a VM will be started during system bootup. Ostype *string `url:"ostype,omitempty",json:"ostype,omitempty"` // Specify guest operating system. Paralleln *string `url:"parallel[n],omitempty",json:"parallel[n],omitempty"` // Map host parallel devices (n is 0 to 2). Protection *bool `url:"protection,omitempty",json:"protection,omitempty"` // Sets the protection flag of the VM. This will disable the remove VM and remove disk operations. Reboot *bool `url:"reboot,omitempty",json:"reboot,omitempty"` // Allow reboot. If set to '0' the VM exit on reboot. Revert *string `url:"revert,omitempty",json:"revert,omitempty"` // Revert a pending change. Rng0 *string `url:"rng0,omitempty",json:"rng0,omitempty"` // Configure a VirtIO-based Random Number Generator. Satan *string `url:"sata[n],omitempty",json:"sata[n],omitempty"` // Use volume as SATA hard disk or CD-ROM (n is 0 to 5). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Scsihw *string `url:"scsihw,omitempty",json:"scsihw,omitempty"` // SCSI controller model Scsin *string `url:"scsi[n],omitempty",json:"scsi[n],omitempty"` // Use volume as SCSI hard disk or CD-ROM (n is 0 to 30). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Searchdomain *string `url:"searchdomain,omitempty",json:"searchdomain,omitempty"` // cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Serialn *string `url:"serial[n],omitempty",json:"serial[n],omitempty"` // Create a serial device inside the VM (n is 0 to 3) Skiplock *bool `url:"skiplock,omitempty",json:"skiplock,omitempty"` // Ignore locks - only root is allowed to use this option. Smbios1 *string `url:"smbios1,omitempty",json:"smbios1,omitempty"` // Specify SMBIOS type 1 fields. Smp *int `url:"smp,omitempty",json:"smp,omitempty"` // The number of CPUs. Please use option -sockets instead. Sockets *int `url:"sockets,omitempty",json:"sockets,omitempty"` // The number of CPU sockets. SpiceEnhancements *string `url:"spice_enhancements,omitempty",json:"spice_enhancements,omitempty"` // Configure additional enhancements for SPICE. Sshkeys *string `url:"sshkeys,omitempty",json:"sshkeys,omitempty"` // cloud-init: Setup public SSH keys (one key per line, OpenSSH format). Startdate *string `url:"startdate,omitempty",json:"startdate,omitempty"` // Set the initial date of the real time clock. Valid format for date are:'now' or '2006-06-17T16:01:21' or '2006-06-17'. Startup *string `url:"startup,omitempty",json:"startup,omitempty"` // Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped. Tablet *bool `url:"tablet,omitempty",json:"tablet,omitempty"` // Enable/disable the USB tablet device. Tags *string `url:"tags,omitempty",json:"tags,omitempty"` // Tags of the VM. This is only meta information. Tdf *bool `url:"tdf,omitempty",json:"tdf,omitempty"` // Enable/disable time drift fix. Template *bool `url:"template,omitempty",json:"template,omitempty"` // Enable/disable Template. Tpmstate0 *string `url:"tpmstate0,omitempty",json:"tpmstate0,omitempty"` // Configure a Disk for storing TPM state. The format is fixed to 'raw'. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and 4 MiB will be used instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Unusedn *string `url:"unused[n],omitempty",json:"unused[n],omitempty"` // Reference to unused volumes. This is used internally, and should not be modified manually. Usbn *string `url:"usb[n],omitempty",json:"usb[n],omitempty"` // Configure an USB device (n is 0 to 4, for machine version >= 7.1 and ostype l26 or windows > 7, n can be up to 14). Vcpus *int `url:"vcpus,omitempty",json:"vcpus,omitempty"` // Number of hotplugged vcpus. Vga *string `url:"vga,omitempty",json:"vga,omitempty"` // Configure the VGA hardware. Virtion *string `url:"virtio[n],omitempty",json:"virtio[n],omitempty"` // Use volume as VIRTIO hard disk (n is 0 to 15). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Vmgenid *string `url:"vmgenid,omitempty",json:"vmgenid,omitempty"` // Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly. Vmstatestorage *string `url:"vmstatestorage,omitempty",json:"vmstatestorage,omitempty"` // Default storage for VM state volumes/files. Watchdog *string `url:"watchdog,omitempty",json:"watchdog,omitempty"` // Create a virtual hardware watchdog device. }
type UpdateVmAsyncConfigResponse ¶
type UpdateVmAsyncConfigResponse *string
type UpdateVmConfigRequest ¶
type UpdateVmConfigRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Acpi *bool `url:"acpi,omitempty",json:"acpi,omitempty"` // Enable/disable ACPI. Affinity *string `url:"affinity,omitempty",json:"affinity,omitempty"` // List of host cores used to execute guest processes, for example: 0,5,8-11 Agent *string `url:"agent,omitempty",json:"agent,omitempty"` // Enable/disable communication with the Qemu Guest Agent and its properties. Arch *string `url:"arch,omitempty",json:"arch,omitempty"` // Virtual processor architecture. Defaults to the host. Args *string `url:"args,omitempty",json:"args,omitempty"` // Arbitrary arguments passed to kvm. Audio0 *string `url:"audio0,omitempty",json:"audio0,omitempty"` // Configure a audio device, useful in combination with QXL/Spice. Autostart *bool `url:"autostart,omitempty",json:"autostart,omitempty"` // Automatic restart after crash (currently ignored). Balloon *int `url:"balloon,omitempty",json:"balloon,omitempty"` // Amount of target RAM for the VM in MB. Using zero disables the ballon driver. Bios *string `url:"bios,omitempty",json:"bios,omitempty"` // Select BIOS implementation. Boot *string `url:"boot,omitempty",json:"boot,omitempty"` // Specify guest boot order. Use the 'order=' sub-property as usage with no key or 'legacy=' is deprecated. Bootdisk *string `url:"bootdisk,omitempty",json:"bootdisk,omitempty"` // Enable booting from specified disk. Deprecated: Use 'boot: order=foo;bar' instead. Cdrom *string `url:"cdrom,omitempty",json:"cdrom,omitempty"` // This is an alias for option -ide2 Cicustom *string `url:"cicustom,omitempty",json:"cicustom,omitempty"` // cloud-init: Specify custom files to replace the automatically generated ones at start. Cipassword *string `url:"cipassword,omitempty",json:"cipassword,omitempty"` // cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords. Citype *string `url:"citype,omitempty",json:"citype,omitempty"` // Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows. Ciuser *string `url:"ciuser,omitempty",json:"ciuser,omitempty"` // cloud-init: User name to change ssh keys and password for instead of the image's configured default user. Cores *int `url:"cores,omitempty",json:"cores,omitempty"` // The number of cores per socket. Cpu *string `url:"cpu,omitempty",json:"cpu,omitempty"` // Emulated CPU type. Cpulimit *float64 `url:"cpulimit,omitempty",json:"cpulimit,omitempty"` // Limit of CPU usage. Cpuunits *int `url:"cpuunits,omitempty",json:"cpuunits,omitempty"` // CPU weight for a VM, will be clamped to [1, 10000] in cgroup v2. Delete *string `url:"delete,omitempty",json:"delete,omitempty"` // A list of settings you want to delete. Description *string `url:"description,omitempty",json:"description,omitempty"` // Description for the VM. Shown in the web-interface VM's summary. This is saved as comment inside the configuration file. Digest *string `url:"digest,omitempty",json:"digest,omitempty"` // Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. Efidisk0 *string `url:"efidisk0,omitempty",json:"efidisk0,omitempty"` // Configure a Disk for storing EFI vars. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and that the default EFI vars are copied to the volume instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Force *bool `url:"force,omitempty",json:"force,omitempty"` // Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal. Freeze *bool `url:"freeze,omitempty",json:"freeze,omitempty"` // Freeze CPU at startup (use 'c' monitor command to start execution). Hookscript *string `url:"hookscript,omitempty",json:"hookscript,omitempty"` // Script that will be executed during various steps in the vms lifetime. Hostpcin *string `url:"hostpci[n],omitempty",json:"hostpci[n],omitempty"` // Map host PCI devices into guest. Hotplug *string `url:"hotplug,omitempty",json:"hotplug,omitempty"` // Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory', 'usb' and 'cloudinit'. Use '0' to disable hotplug completely. Using '1' as value is an alias for the default `network,disk,usb`. USB hotplugging is possible for guests with machine version >= 7.1 and ostype l26 or windows > 7. Hugepages *string `url:"hugepages,omitempty",json:"hugepages,omitempty"` // Enable/disable hugepages memory. Iden *string `url:"ide[n],omitempty",json:"ide[n],omitempty"` // Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Ipconfign *string `url:"ipconfig[n],omitempty",json:"ipconfig[n],omitempty"` // cloud-init: Specify IP addresses and gateways for the corresponding interface.IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicitgateway should be provided.For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requirescloud-init 19.4 or newer.If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to usingdhcp on IPv4. Ivshmem *string `url:"ivshmem,omitempty",json:"ivshmem,omitempty"` // Inter-VM shared memory. Useful for direct communication between VMs, or to the host. Keephugepages *bool `url:"keephugepages,omitempty",json:"keephugepages,omitempty"` // Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. Keyboard *string `url:"keyboard,omitempty",json:"keyboard,omitempty"` // Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. Kvm *bool `url:"kvm,omitempty",json:"kvm,omitempty"` // Enable/disable KVM hardware virtualization. Localtime *bool `url:"localtime,omitempty",json:"localtime,omitempty"` // Set the real time clock (RTC) to local time. This is enabled by default if the `ostype` indicates a Microsoft Windows OS. Lock *string `url:"lock,omitempty",json:"lock,omitempty"` // Lock/unlock the VM. Machine *string `url:"machine,omitempty",json:"machine,omitempty"` // Specifies the Qemu machine type. Memory *int `url:"memory,omitempty",json:"memory,omitempty"` // Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device. MigrateDowntime *float64 `url:"migrate_downtime,omitempty",json:"migrate_downtime,omitempty"` // Set maximum tolerated downtime (in seconds) for migrations. MigrateSpeed *int `url:"migrate_speed,omitempty",json:"migrate_speed,omitempty"` // Set maximum speed (in MB/s) for migrations. Value 0 is no limit. Name *string `url:"name,omitempty",json:"name,omitempty"` // Set a name for the VM. Only used on the configuration web interface. Nameserver *string `url:"nameserver,omitempty",json:"nameserver,omitempty"` // cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Netn *string `url:"net[n],omitempty",json:"net[n],omitempty"` // Specify network devices. Numa *bool `url:"numa,omitempty",json:"numa,omitempty"` // Enable/disable NUMA. Numan *string `url:"numa[n],omitempty",json:"numa[n],omitempty"` // NUMA topology. Onboot *bool `url:"onboot,omitempty",json:"onboot,omitempty"` // Specifies whether a VM will be started during system bootup. Ostype *string `url:"ostype,omitempty",json:"ostype,omitempty"` // Specify guest operating system. Paralleln *string `url:"parallel[n],omitempty",json:"parallel[n],omitempty"` // Map host parallel devices (n is 0 to 2). Protection *bool `url:"protection,omitempty",json:"protection,omitempty"` // Sets the protection flag of the VM. This will disable the remove VM and remove disk operations. Reboot *bool `url:"reboot,omitempty",json:"reboot,omitempty"` // Allow reboot. If set to '0' the VM exit on reboot. Revert *string `url:"revert,omitempty",json:"revert,omitempty"` // Revert a pending change. Rng0 *string `url:"rng0,omitempty",json:"rng0,omitempty"` // Configure a VirtIO-based Random Number Generator. Satan *string `url:"sata[n],omitempty",json:"sata[n],omitempty"` // Use volume as SATA hard disk or CD-ROM (n is 0 to 5). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Scsihw *string `url:"scsihw,omitempty",json:"scsihw,omitempty"` // SCSI controller model Scsin *string `url:"scsi[n],omitempty",json:"scsi[n],omitempty"` // Use volume as SCSI hard disk or CD-ROM (n is 0 to 30). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Searchdomain *string `url:"searchdomain,omitempty",json:"searchdomain,omitempty"` // cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Serialn *string `url:"serial[n],omitempty",json:"serial[n],omitempty"` // Create a serial device inside the VM (n is 0 to 3) Skiplock *bool `url:"skiplock,omitempty",json:"skiplock,omitempty"` // Ignore locks - only root is allowed to use this option. Smbios1 *string `url:"smbios1,omitempty",json:"smbios1,omitempty"` // Specify SMBIOS type 1 fields. Smp *int `url:"smp,omitempty",json:"smp,omitempty"` // The number of CPUs. Please use option -sockets instead. Sockets *int `url:"sockets,omitempty",json:"sockets,omitempty"` // The number of CPU sockets. SpiceEnhancements *string `url:"spice_enhancements,omitempty",json:"spice_enhancements,omitempty"` // Configure additional enhancements for SPICE. Sshkeys *string `url:"sshkeys,omitempty",json:"sshkeys,omitempty"` // cloud-init: Setup public SSH keys (one key per line, OpenSSH format). Startdate *string `url:"startdate,omitempty",json:"startdate,omitempty"` // Set the initial date of the real time clock. Valid format for date are:'now' or '2006-06-17T16:01:21' or '2006-06-17'. Startup *string `url:"startup,omitempty",json:"startup,omitempty"` // Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped. Tablet *bool `url:"tablet,omitempty",json:"tablet,omitempty"` // Enable/disable the USB tablet device. Tags *string `url:"tags,omitempty",json:"tags,omitempty"` // Tags of the VM. This is only meta information. Tdf *bool `url:"tdf,omitempty",json:"tdf,omitempty"` // Enable/disable time drift fix. Template *bool `url:"template,omitempty",json:"template,omitempty"` // Enable/disable Template. Tpmstate0 *string `url:"tpmstate0,omitempty",json:"tpmstate0,omitempty"` // Configure a Disk for storing TPM state. The format is fixed to 'raw'. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Note that SIZE_IN_GiB is ignored here and 4 MiB will be used instead. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Unusedn *string `url:"unused[n],omitempty",json:"unused[n],omitempty"` // Reference to unused volumes. This is used internally, and should not be modified manually. Usbn *string `url:"usb[n],omitempty",json:"usb[n],omitempty"` // Configure an USB device (n is 0 to 4, for machine version >= 7.1 and ostype l26 or windows > 7, n can be up to 14). Vcpus *int `url:"vcpus,omitempty",json:"vcpus,omitempty"` // Number of hotplugged vcpus. Vga *string `url:"vga,omitempty",json:"vga,omitempty"` // Configure the VGA hardware. Virtion *string `url:"virtio[n],omitempty",json:"virtio[n],omitempty"` // Use volume as VIRTIO hard disk (n is 0 to 15). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. Vmgenid *string `url:"vmgenid,omitempty",json:"vmgenid,omitempty"` // Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly. Vmstatestorage *string `url:"vmstatestorage,omitempty",json:"vmstatestorage,omitempty"` // Default storage for VM state volumes/files. Watchdog *string `url:"watchdog,omitempty",json:"watchdog,omitempty"` // Create a virtual hardware watchdog device. }
type UpdateVmConfigResponse ¶
type UpdateVmConfigResponse map[string]interface{}
type VmConfigRequest ¶
type VmConfigRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Current *bool `url:"current,omitempty",json:"current,omitempty"` // Get current values (instead of pending values). Snapshot *string `url:"snapshot,omitempty",json:"snapshot,omitempty"` // Fetch config values from given snapshot. }
type VmConfigResponse ¶
type VmConfigResponse struct { Digest string `url:"digest",json:"digest"` // SHA1 digest of configuration file. This can be used to prevent concurrent modifications. // The following parameters are optional Acpi *bool `url:"acpi,omitempty",json:"acpi,omitempty"` // Enable/disable ACPI. Affinity *string `url:"affinity,omitempty",json:"affinity,omitempty"` // List of host cores used to execute guest processes, for example: 0,5,8-11 Agent *string `url:"agent,omitempty",json:"agent,omitempty"` // Enable/disable communication with the Qemu Guest Agent and its properties. Arch *string `url:"arch,omitempty",json:"arch,omitempty"` // Virtual processor architecture. Defaults to the host. Args *string `url:"args,omitempty",json:"args,omitempty"` // Arbitrary arguments passed to kvm. Audio0 *string `url:"audio0,omitempty",json:"audio0,omitempty"` // Configure a audio device, useful in combination with QXL/Spice. Autostart *bool `url:"autostart,omitempty",json:"autostart,omitempty"` // Automatic restart after crash (currently ignored). Balloon *int `url:"balloon,omitempty",json:"balloon,omitempty"` // Amount of target RAM for the VM in MB. Using zero disables the ballon driver. Bios *string `url:"bios,omitempty",json:"bios,omitempty"` // Select BIOS implementation. Boot *string `url:"boot,omitempty",json:"boot,omitempty"` // Specify guest boot order. Use the 'order=' sub-property as usage with no key or 'legacy=' is deprecated. Bootdisk *string `url:"bootdisk,omitempty",json:"bootdisk,omitempty"` // Enable booting from specified disk. Deprecated: Use 'boot: order=foo;bar' instead. Cdrom *string `url:"cdrom,omitempty",json:"cdrom,omitempty"` // This is an alias for option -ide2 Cicustom *string `url:"cicustom,omitempty",json:"cicustom,omitempty"` // cloud-init: Specify custom files to replace the automatically generated ones at start. Cipassword *string `url:"cipassword,omitempty",json:"cipassword,omitempty"` // cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords. Citype *string `url:"citype,omitempty",json:"citype,omitempty"` // Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows. Ciuser *string `url:"ciuser,omitempty",json:"ciuser,omitempty"` // cloud-init: User name to change ssh keys and password for instead of the image's configured default user. Cores *int `url:"cores,omitempty",json:"cores,omitempty"` // The number of cores per socket. Cpu *string `url:"cpu,omitempty",json:"cpu,omitempty"` // Emulated CPU type. Cpulimit *float64 `url:"cpulimit,omitempty",json:"cpulimit,omitempty"` // Limit of CPU usage. Cpuunits *int `url:"cpuunits,omitempty",json:"cpuunits,omitempty"` // CPU weight for a VM, will be clamped to [1, 10000] in cgroup v2. Description *string `url:"description,omitempty",json:"description,omitempty"` // Description for the VM. Shown in the web-interface VM's summary. This is saved as comment inside the configuration file. Efidisk0 *string `url:"efidisk0,omitempty",json:"efidisk0,omitempty"` // Configure a Disk for storing EFI vars. Freeze *bool `url:"freeze,omitempty",json:"freeze,omitempty"` // Freeze CPU at startup (use 'c' monitor command to start execution). Hookscript *string `url:"hookscript,omitempty",json:"hookscript,omitempty"` // Script that will be executed during various steps in the vms lifetime. Hostpcin *string `url:"hostpci[n],omitempty",json:"hostpci[n],omitempty"` // Map host PCI devices into guest. Hotplug *string `url:"hotplug,omitempty",json:"hotplug,omitempty"` // Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory', 'usb' and 'cloudinit'. Use '0' to disable hotplug completely. Using '1' as value is an alias for the default `network,disk,usb`. USB hotplugging is possible for guests with machine version >= 7.1 and ostype l26 or windows > 7. Hugepages *string `url:"hugepages,omitempty",json:"hugepages,omitempty"` // Enable/disable hugepages memory. Iden *string `url:"ide[n],omitempty",json:"ide[n],omitempty"` // Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Ipconfign *string `url:"ipconfig[n],omitempty",json:"ipconfig[n],omitempty"` // cloud-init: Specify IP addresses and gateways for the corresponding interface.IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicitgateway should be provided.For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requirescloud-init 19.4 or newer.If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to usingdhcp on IPv4. Ivshmem *string `url:"ivshmem,omitempty",json:"ivshmem,omitempty"` // Inter-VM shared memory. Useful for direct communication between VMs, or to the host. Keephugepages *bool `url:"keephugepages,omitempty",json:"keephugepages,omitempty"` // Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. Keyboard *string `url:"keyboard,omitempty",json:"keyboard,omitempty"` // Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. Kvm *bool `url:"kvm,omitempty",json:"kvm,omitempty"` // Enable/disable KVM hardware virtualization. Localtime *bool `url:"localtime,omitempty",json:"localtime,omitempty"` // Set the real time clock (RTC) to local time. This is enabled by default if the `ostype` indicates a Microsoft Windows OS. Lock *string `url:"lock,omitempty",json:"lock,omitempty"` // Lock/unlock the VM. Machine *string `url:"machine,omitempty",json:"machine,omitempty"` // Specifies the Qemu machine type. Memory *int `url:"memory,omitempty",json:"memory,omitempty"` // Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device. MigrateDowntime *float64 `url:"migrate_downtime,omitempty",json:"migrate_downtime,omitempty"` // Set maximum tolerated downtime (in seconds) for migrations. MigrateSpeed *int `url:"migrate_speed,omitempty",json:"migrate_speed,omitempty"` // Set maximum speed (in MB/s) for migrations. Value 0 is no limit. Name *string `url:"name,omitempty",json:"name,omitempty"` // Set a name for the VM. Only used on the configuration web interface. Nameserver *string `url:"nameserver,omitempty",json:"nameserver,omitempty"` // cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Netn *string `url:"net[n],omitempty",json:"net[n],omitempty"` // Specify network devices. Numa *bool `url:"numa,omitempty",json:"numa,omitempty"` // Enable/disable NUMA. Numan *string `url:"numa[n],omitempty",json:"numa[n],omitempty"` // NUMA topology. Onboot *bool `url:"onboot,omitempty",json:"onboot,omitempty"` // Specifies whether a VM will be started during system bootup. Ostype *string `url:"ostype,omitempty",json:"ostype,omitempty"` // Specify guest operating system. Paralleln *string `url:"parallel[n],omitempty",json:"parallel[n],omitempty"` // Map host parallel devices (n is 0 to 2). Protection *bool `url:"protection,omitempty",json:"protection,omitempty"` // Sets the protection flag of the VM. This will disable the remove VM and remove disk operations. Reboot *bool `url:"reboot,omitempty",json:"reboot,omitempty"` // Allow reboot. If set to '0' the VM exit on reboot. Rng0 *string `url:"rng0,omitempty",json:"rng0,omitempty"` // Configure a VirtIO-based Random Number Generator. Satan *string `url:"sata[n],omitempty",json:"sata[n],omitempty"` // Use volume as SATA hard disk or CD-ROM (n is 0 to 5). Scsihw *string `url:"scsihw,omitempty",json:"scsihw,omitempty"` // SCSI controller model Scsin *string `url:"scsi[n],omitempty",json:"scsi[n],omitempty"` // Use volume as SCSI hard disk or CD-ROM (n is 0 to 30). Searchdomain *string `url:"searchdomain,omitempty",json:"searchdomain,omitempty"` // cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set. Serialn *string `url:"serial[n],omitempty",json:"serial[n],omitempty"` // Create a serial device inside the VM (n is 0 to 3) Smbios1 *string `url:"smbios1,omitempty",json:"smbios1,omitempty"` // Specify SMBIOS type 1 fields. Smp *int `url:"smp,omitempty",json:"smp,omitempty"` // The number of CPUs. Please use option -sockets instead. Sockets *int `url:"sockets,omitempty",json:"sockets,omitempty"` // The number of CPU sockets. SpiceEnhancements *string `url:"spice_enhancements,omitempty",json:"spice_enhancements,omitempty"` // Configure additional enhancements for SPICE. Sshkeys *string `url:"sshkeys,omitempty",json:"sshkeys,omitempty"` // cloud-init: Setup public SSH keys (one key per line, OpenSSH format). Startdate *string `url:"startdate,omitempty",json:"startdate,omitempty"` // Set the initial date of the real time clock. Valid format for date are:'now' or '2006-06-17T16:01:21' or '2006-06-17'. Startup *string `url:"startup,omitempty",json:"startup,omitempty"` // Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped. Tablet *bool `url:"tablet,omitempty",json:"tablet,omitempty"` // Enable/disable the USB tablet device. Tags *string `url:"tags,omitempty",json:"tags,omitempty"` // Tags of the VM. This is only meta information. Tdf *bool `url:"tdf,omitempty",json:"tdf,omitempty"` // Enable/disable time drift fix. Template *bool `url:"template,omitempty",json:"template,omitempty"` // Enable/disable Template. Tpmstate0 *string `url:"tpmstate0,omitempty",json:"tpmstate0,omitempty"` // Configure a Disk for storing TPM state. The format is fixed to 'raw'. Unusedn *string `url:"unused[n],omitempty",json:"unused[n],omitempty"` // Reference to unused volumes. This is used internally, and should not be modified manually. Usbn *string `url:"usb[n],omitempty",json:"usb[n],omitempty"` // Configure an USB device (n is 0 to 4, for machine version >= 7.1 and ostype l26 or windows > 7, n can be up to 14). Vcpus *int `url:"vcpus,omitempty",json:"vcpus,omitempty"` // Number of hotplugged vcpus. Vga *string `url:"vga,omitempty",json:"vga,omitempty"` // Configure the VGA hardware. Virtion *string `url:"virtio[n],omitempty",json:"virtio[n],omitempty"` // Use volume as VIRTIO hard disk (n is 0 to 15). Vmgenid *string `url:"vmgenid,omitempty",json:"vmgenid,omitempty"` // Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly. Vmstatestorage *string `url:"vmstatestorage,omitempty",json:"vmstatestorage,omitempty"` // Default storage for VM state volumes/files. Watchdog *string `url:"watchdog,omitempty",json:"watchdog,omitempty"` // Create a virtual hardware watchdog device. }
type VmFeatureRequest ¶
type VmFeatureRequest struct { Feature string `url:"feature",json:"feature"` // Feature to check. Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Snapname *string `url:"snapname,omitempty",json:"snapname,omitempty"` // The name of the snapshot. }
type VmFeatureResponse ¶
type VmPendingRequest ¶
type VmPendingResponse ¶
type VmPendingResponse []*struct { Key string `url:"key",json:"key"` // Configuration option name. // The following parameters are optional Delete *int `url:"delete,omitempty",json:"delete,omitempty"` // Indicates a pending delete request if present and not 0. The value 2 indicates a force-delete request. Pending *string `url:"pending,omitempty",json:"pending,omitempty"` // Pending value. Value *string `url:"value,omitempty",json:"value,omitempty"` // Current value. }
type VmSendkeyRequest ¶
type VmSendkeyRequest struct { Key string `url:"key",json:"key"` // The key (qemu monitor encoding). Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional Skiplock *bool `url:"skiplock,omitempty",json:"skiplock,omitempty"` // Ignore locks - only root is allowed to use this option. }
type VmSendkeyResponse ¶
type VmSendkeyResponse map[string]interface{}
type VncproxyRequest ¶
type VncproxyRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. // The following parameters are optional GeneratePassword *bool `url:"generate-password,omitempty",json:"generate-password,omitempty"` // Generates a random password to be used as ticket instead of the API ticket. Websocket *bool `url:"websocket,omitempty",json:"websocket,omitempty"` // starts websockify instead of vncproxy }
type VncproxyResponse ¶
type VncproxyResponse struct { Cert string `url:"cert",json:"cert"` Port int `url:"port",json:"port"` Ticket string `url:"ticket",json:"ticket"` Upid string `url:"upid",json:"upid"` User string `url:"user",json:"user"` // The following parameters are optional Password *string `url:"password,omitempty",json:"password,omitempty"` // Returned if requested with 'generate-password' param. Consists of printable ASCII characters ('!' .. '~'). }
type VncwebsocketRequest ¶
type VncwebsocketRequest struct { Node string `url:"node",json:"node"` // The cluster node name. Port int `url:"port",json:"port"` // Port number returned by previous vncproxy call. Vmid int `url:"vmid",json:"vmid"` // The (unique) ID of the VM. Vncticket string `url:"vncticket",json:"vncticket"` // Ticket from previous call to vncproxy. }
type VncwebsocketResponse ¶
type VncwebsocketResponse struct {
Port string `url:"port",json:"port"`
}