phenix image¶
Every command on this page also accepts the global flags.
phenix image¶
Virtual disk image management
Options¶
SEE ALSO¶
- phenix - A cli application for phēnix
- phenix image append - Append to an image configuration
- phenix image build - Build a virtual disk image
- phenix image create - Create a disk image configuration
- phenix image create-from - Create image configuration from existing one
- phenix image delete - Delete one or more image configurations
- phenix image edit - Edit an image
- phenix image inject-miniexe - Inject a minimega executable into a disk image
- phenix image list - Table of image configurations
- phenix image remove - Remove from an image configuration
- phenix image update - Reread the scripts of an image configuration from disk
phenix image append¶
Append to an image configuration
Synopsis¶
Append to an image configuration
Used to add scripts, packages, and/or overlays to an existing virtual disk
image configuration.
Options¶
-h, --help help for append
-O, --overlays string List of overlay names (include full path; separated by comma)
-P, --packages string List of packages to include in addition to those provided by variant (separated by comma)
-T, --scripts string List of scripts to include in addition to the defaults (include full path; separated by comma)
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image build¶
Build a virtual disk image
Synopsis¶
Build a virtual disk image
Used to build a new virtual disk using an existing configuration; vmdb2 must
be in path.
Examples¶
Options¶
-c, --cache Cache rootfs as tar archive
--dry-run Do everything but actually call out to vmdb2
-h, --help help for build
-o, --output string Specify the output directory for the disk image to be saved to
-v, --verbose Enable verbose output
-x, --very-verbose Enable very verbose output, additionally writes output log file to <image name>.log
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image create¶
Create a disk image configuration
Synopsis¶
Create a disk image configuration
Used to create a virtual disk image configuration from which to build
an image.
When specifying the --size option, the following units can be used:
M - Megabytes
G - Gigabytes
Examples¶
phenix image create <image name>
phenix image create --size 2G --variant mingui --release noble --compress --overlays foobar --packages foo --scripts bar <image name>
Options¶
-l, --components string List of components from the mirror to download packages from (separated by comma)
-c, --compress Compress image after creation (does not apply to raw image)
-f, --format string Format of disk image (default "qcow2")
-h, --help help for create
-k, --kernel-args string List of parameters which grub will pass to the Linux kernel (e.g. 'net.ifnames=0','consoleblank=0'); separated by comma). Warning: each comma starts a new parameter, so a value with a comma, such as console=ttyS0,115200n8, is split, which can make the build fail.
-m, --mirror string Debootstrap mirror (must match release) (default "http://us.archive.ubuntu.com/ubuntu")
--no-virtuals Don't add virtual filesystem mounts to chroot before executing scripts when running vmdb2 (default is 'false')
-O, --overlays string List of overlay names (include full path; separated by comma)
-P, --packages string List of packages to include in addition to those provided by variant (separated by comma)
-R, --ramdisk Create a kernel/initrd pair in addition to a disk image
-r, --release string OS release codename (default "noble")
-T, --scripts string List of scripts to include in addition to the defaults (include full path; separated by comma)
-s, --size string Image size to use (default "10G")
--skip-default-pkgs Skip default packages typically included in all builds
-v, --variant string Image variant to use (default "minbase")
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image create-from¶
Create image configuration from existing one
Synopsis¶
Create image configuration from existing one
Used to create a new virtual disk image configuration from an existing one;
if options are used they will be added to the existing configuration.
Options¶
-h, --help help for create-from
-O, --overlays string List of overlay names (include full path; separated by comma)
-P, --packages string List of packages to include in addition to those provided by variant (separated by comma)
-T, --scripts string List of scripts to include in addition to the defaults (include full path; separated by comma)
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image delete¶
Delete one or more image configurations
Synopsis¶
Delete one or more image configurations
When phenix cannot delete an image configuration, it continues with the
other ones. Then it exits with an error that names each failure.
A name can contain the wildcard *, which matches zero or more characters.
For example, cm-* selects each image configuration whose name starts with
"cm-", and * selects all of them. Put quotation marks around a pattern, so
that your shell does not expand it. Before phenix deletes the image
configurations that a pattern selects, it shows their names. Another
pattern that selects no image configuration is an error.
With --dry-run, phenix shows the image configurations that it would
delete, and deletes nothing.
Examples¶
phenix image delete ubuntu
phenix image delete ubuntu kali-mini
phenix image delete 'cm-*'
phenix image delete 'cm-*' --dry-run
Options¶
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image edit¶
Edit an image
Synopsis¶
Options¶
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image inject-miniexe¶
Inject a minimega executable into a disk image
Synopsis¶
Inject a minimega executable into a disk image
Used to add a minimega executable (miniccc, protonuke, or minirouter) and
relevant boot scripts into an existing disk image. The disk operating system
is guessed based on the provided agent's extension. When specifying the path
to the disk to modify, the partition to inject into can optionally be included
at the end of the path using a colon (for example, /phenix/images/foo.qc2:2).
If not specified, partition 1 will be assumed.
In a Windows disk image, the minimega executable will be injected into
C:\minimega\[miniccc,protonuke]. A scheduler command will be placed into the
Windows Startup directory for miniccc if '--init-system=startup' is provided,
but not for protonuke, since protonuke's command line arguments are dynamic.
Users or apps wishing to leverage protonuke on Windows hosts need to inject
their own scheduler command in the Windows Startup directory or use miniccc to
start protonuke.
In a Linux disk image, the minimega executable will be injected into
/usr/local/bin and the service file and symlinks will be injected into the
appropriate locations, depending on which init system is being used. For
systemd, they will be injected into /etc/systemd/system, and for sysinitv they
will be injected into /etc/init.d and /etc/rc5.d. The protonuke service will
only start if a file is present at /etc/default/protonuke, and that file
should contain a single line setting the PROTONUKE_ARGS variable to a set of
protonuke command line arguments. The minirouter service expects the miniccc
service to be injected, and injecting minirouter will automatically cause
miniccc to be injected as well.
Options¶
-h, --help help for inject-miniexe
--init-system string Linux init system to generate boot scripts for (Linux: systemd, sysinitv; Windows: startup) (default "systemd")
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image list¶
Table of image configurations
Synopsis¶
Table of image configurations
-f, -c and -m add columns to the table. The JSON and YAML output always
have those values.
Options¶
-c, --compressed Include disk compression
-f, --format Include disk image format
-h, --help help for list
-m, --mirror Include debootstrap mirror
-o, --output string Output format (table, json, yaml) (default "table")
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image remove¶
Remove from an image configuration
Synopsis¶
Remove from an image configuration
Used to remove scripts, packages, and/or overlays to an existing virtual disk
image configuration
Options¶
-h, --help help for remove
-O, --overlays string List of overlay names (include full path; separated by comma)
-P, --packages string List of packages to include in addition to those provided by variant (separated by comma)
-T, --scripts string List of scripts to include in addition to the defaults (include full path; separated by comma)
SEE ALSO¶
- phenix image - Virtual disk image management
phenix image update¶
Reread the scripts of an image configuration from disk
Synopsis¶
Reread the scripts of an image configuration
Reads again each script of an existing virtual disk image configuration from
its file on disk, and stores the new contents in the configuration. A script
that is a URL, or whose file is not on disk, keeps its stored contents. The
scripts keep their order.
Note: this command does not add or remove scripts, and does not change
packages or overlays. Use 'phenix image append' or 'phenix image remove' for
those.
Options¶
SEE ALSO¶
- phenix image - Virtual disk image management