Zudoku
unikraft instances

unikraft instances edit

Edit an instance.

Code
unikraft instances edit <target> [flags]

Examples

Resize instance memory:

TerminalCode
unikraft instance edit demo-instance --memory 256

Attach a ROM image to an instance:

TerminalCode
unikraft instance edit demo-instance \ --set roms=name=my-rom,image=myuser/my-rom:latest,at=/rom0

Add a ROM to an instance without replacing existing ones:

TerminalCode
unikraft instance edit demo-instance \ --add roms=name=mydata,dir=./mydata,at=/rom

Remove a ROM from an instance by name:

TerminalCode
unikraft instance edit demo-instance --del roms=my-rom

Attach a volume to an instance:

TerminalCode
unikraft instance edit demo-instance --add volumes=my-vol:/data

Detach a volume from an instance:

TerminalCode
unikraft instance edit demo-instance --del volumes=my-vol

Options

Code
--add <name>=<value> Key-value pairs to add to the instance. --add-file <name>=<filename> Files containing key-value pairs to add to the instance. --annotation <key>=<value> Instance annotation. --args arg Arguments to pass to the instance. --autokill <key>=<value> Autokill options. time: time after the instance stops before it is deleted num-requests: max requests before the instance is deleted --cmd CMD Run a command to edit fields (receives YAML on stdin, outputs edited YAML on stdout). --del <name>=<value> Keys to delete from the instance. --del-file <name>=<filename> Files containing keys to delete from the instance. --delete-lock Prevent instance deletion until the lock is removed. --dry-run Print patches without applying them. -e, --env <key>=<value> Environment variable. -f, --field FIELD Specify which fields to include in the output. --image <name>:<tag> Image to deploy. --load LOAD Load fields from a YAML file. -m, --memory size Memory allocation. -o, --output OUTPUT Output format. One of: kv, table, json, yaml, raw, quiet, template. --plugin name=<name>,image=<ref>[,config=<json>] Load plugin into the instance. --rom name=<name>,image=<ref>,at=<path> Attach ROM. --save FILE Save editable fields as YAML to a file (use - for stdout). --scale-to-zero <key>=<value> Scale-to-zero options. policy: on | idle | off cooldown-time: cooldown in ms before scaling to zero notify-time: notification time in ms before scaling to zero stateful: true | false --sched-priority priority Scheduling priority for the instance. --set <name>=<value> Key-value pairs to set on the instance. --set-file <name>=<filename> Files containing key-value pairs to set on the instance. --tag tag Instance tag. --vcpus n Number of vCPUs. --visual Open an editor to modify fields visually.

Options inherited from parent commands

Code
--config file Path to the configuration file. --log-level level Set the logging level. (default info) --log-type type Set the log type. (default text) --profile name Set the current profile. --telemetry Toggle usage analytics. (default true) --timeout duration Set a deadline for the command (e.g. 30s, 5m, 1h).

See Also

Last modified on