pub struct PostParams {Show 43 fields
pub arch: Option<Arch>,
pub bwlimit: Option<()>,
pub cmode: Option<Cmode>,
pub console: Option<bool>,
pub cores: Option<u64>,
pub cpulimit: Option<f64>,
pub cpuunits: Option<()>,
pub debug: Option<bool>,
pub description: Option<String>,
pub devs: HashMap<u32, String>,
pub features: Option<String>,
pub force: Option<bool>,
pub hookscript: Option<String>,
pub hostname: Option<String>,
pub ignore_unpack_errors: Option<bool>,
pub lock: Option<Lock>,
pub memory: Option<u64>,
pub mps: HashMap<u32, String>,
pub nameserver: Option<String>,
pub nets: HashMap<u32, String>,
pub onboot: Option<bool>,
pub ostemplate: String,
pub ostype: Option<Ostype>,
pub password: Option<String>,
pub pool: Option<String>,
pub protection: Option<bool>,
pub restore: Option<bool>,
pub rootfs: Option<String>,
pub searchdomain: Option<String>,
pub ssh_public_keys: Option<String>,
pub start: Option<bool>,
pub startup: Option<String>,
pub storage: Option<String>,
pub swap: Option<u64>,
pub tags: Option<String>,
pub template: Option<bool>,
pub timezone: Option<String>,
pub tty: Option<u64>,
pub unique: Option<bool>,
pub unprivileged: Option<bool>,
pub unuseds: HashMap<u32, String>,
pub vmid: VmId,
pub additional_properties: HashMap<String, Value>,
}
Fields§
§arch: Option<Arch>
OS architecture type.
bwlimit: Option<()>
Override I/O bandwidth limit (in KiB/s).
cmode: Option<Cmode>
Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to ‘console’ it tries to attach to /dev/console instead. If you set cmode to ‘shell’, it simply invokes a shell inside the container (no login).
console: Option<bool>
Attach a console device (/dev/console) to the container.
cores: Option<u64>
The number of cores assigned to the container. A container can use all available cores by default.
cpulimit: Option<f64>
Limit of CPU usage.
NOTE: If the computer has 2 CPUs, it has a total of ‘2’ CPU time. Value ‘0’ indicates no CPU limit.
cpuunits: Option<()>
CPU weight for a container, will be clamped to [1, 10000] in cgroup v2. CPU weight for a container. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this container gets. Number is relative to the weights of all the other running guests.
debug: Option<bool>
Try to be more verbose. For now this only enables debug log-level on start.
description: Option<String>
Description for the Container. Shown in the web-interface CT’s summary. This is saved as comment inside the configuration file.
devs: HashMap<u32, String>
Device to pass through to the container
features: Option<String>
Allow containers access to advanced features.
force: Option<bool>
Allow to overwrite existing container.
hookscript: Option<String>
Script that will be exectued during various steps in the containers lifetime.
hostname: Option<String>
Set a host name for the container.
ignore_unpack_errors: Option<bool>
Ignore errors when extracting the template.
lock: Option<Lock>
Lock/unlock the container.
memory: Option<u64>
Amount of RAM for the container in MB.
mps: HashMap<u32, String>
Use volume as container mount point. Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume.
nameserver: Option<String>
Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.
nets: HashMap<u32, String>
Specifies network interfaces for the container.
onboot: Option<bool>
Specifies whether a container will be started during system bootup.
ostemplate: String
The OS template or backup file.
ostype: Option<Ostype>
OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/<ostype>.common.conf. Value ‘unmanaged’ can be used to skip and OS specific setup.
password: Option<String>
Sets root password inside container.
pool: Option<String>
Add the VM to the specified pool.
protection: Option<bool>
Sets the protection flag of the container. This will prevent the CT or CT’s disk remove/update operation.
restore: Option<bool>
Mark this as restore task.
rootfs: Option<String>
Use volume as container root.
searchdomain: Option<String>
Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.
ssh_public_keys: Option<String>
Setup public SSH keys (one key per line, OpenSSH format).
start: Option<bool>
Start the CT after its creation finished successfully.
startup: Option<String>
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: Option<String>
Default Storage.
swap: Option<u64>
Amount of SWAP for the container in MB.
Tags of the Container. This is only meta information.
template: Option<bool>
Enable/disable Template.
timezone: Option<String>
Time zone to use in the container. If option isn’t set, then nothing will be done. Can be set to ‘host’ to match the host time zone, or an arbitrary time zone option from /usr/share/zoneinfo/zone.tab
tty: Option<u64>
Specify the number of tty available to the container
unique: Option<bool>
Assign a unique random ethernet address.
unprivileged: Option<bool>
Makes the container run as unprivileged user. (Should not be modified manually.)
unuseds: HashMap<u32, String>
Reference to unused volumes. This is used internally, and should not be modified manually.
vmid: VmId
The (unique) ID of the VM.
additional_properties: HashMap<String, Value>
Implementations§
Trait Implementations§
Source§impl Clone for PostParams
impl Clone for PostParams
Source§fn clone(&self) -> PostParams
fn clone(&self) -> PostParams
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more