v23
- Added
CleanScripts=
to allow running custom cleanup code whenever
mkosi cleans up the output directory. This allows cleaning up extra
outputs produced by e.g. a build script that mkosi doesn't know about. - Added
ConfigureScripts=
to allow dynamically modifying the mkosi
configuration. Each configure script receives the current config as
JSON on stdin and should output the new config as JSON on stdout. - When building a UKI, we don't measure for the TPM SHA1 PCR bank
anymore. - All keys in the mkosi config JSON output are now in pascal case,
except for credentials and environments, where the keys encode names
of credentials and environment variables and are therefore case
sensitive. - Added various settings to allow running mkosi behind a proxy.
- Various fixes to kernel module filtering that should result in fewer
modules being pulled into the default initrd when
KernelModulesExclude=
orKernelModulesInitrdExclude=
are used. - Added
ToolsTreeDistribution=
match. - Removed
vmspawn
verb and replaced it withVirtualMachineMonitor=
. - New specifiers for various directories were added.
%D
resolves to
the directory that mkosi was invoked in,%P
to the current working
directory, and%C
to the parent directory of the config file. - Added
ForwardJournal=
to have systemd inside a container/VM forward
its journal to the specified file or directory. - Systemd scopes are now allocated for qemu, swtpm, virtiofsd and
systemd-journal-remote if available. - The
mkosi qemu
virtual machine is now registered with
systemd-machined if available. - Added new
oci
output format - Runtime trees without a target are now mounted to
/root/src
instead
of a subdirectory of it (To have the same behaviour as
BuildSources=
). - Added
RuntimeBuildSources=
to mount build and source directories
when booting the image withmkosi nspawn
ormkosi qemu
. - Introduced
--append
to allow command line settings to be parsed
after parsing configuration files. distribution-release
is not installed by default anymore on
OpenSUSE.- Setting
QemuSmp=
to0
will now make qemu use all available CPUs - Free page reporting and discard request processing are now enabled by
default in VMs spawned bymkosi qemu
. - Added
ToolsTreeCertificates=
to allow configuring whether to use
certificates and keys from the tools tree (if one is used) or the
host. - Added
never
forCacheOnly=
to specify that repository metadata
should always be refreshed. - Renamed the
none
option forCacheOnly=
toauto
. - Added
ProxyExclude=
to configure hostnames for which requests should
not go through the configured proxy. - The default tools tree is now reused on incremental builds.
- Added
VolatilePackages=
andInitrdVolatilePackages=
to configure
packages that should be installed after executing build scripts and
which should not be cached when usingIncremental=
. PackageDirectories=
now has an associated default path
mkosi.packages
.reprepro
is now used to generate local apt repositories.- Support for BSD tar/cpio was dropped.
- When both
ExtraSearchPaths=
andToolsTree=
are used, mkosi will
now prefer running a binary found inExtraSearchPaths=
without the
tools tree over running the binary from the tools tree. If a binary is
not found inExtraSearchPaths=
, the tools tree is used instead. - An artifact directory is now made available when running scripts which
can be used to pass around data between different scripts. mkosi will
also look for microcode and initrds in the artifact directory under
theio.mkosi.microcode
andio.mkosi.initrd
subdirectories. - Added
Environment=
match setting to check for environment variables
defined with theEnvironment=
setting. - The
basesystem
package is now always installed in Fedora and
CentOS images instead of thefilesystem
package. - The
qemu
,shell
andboot
verbs do not automatically build the
image anymore unless--force
is specified. SplitArtifacts=
is now supported for the portable, sysext and
confext outputs.- The
WithDocs=
option was implemented for pacman-based distributions. - The default Fedora release was bumped to 40.
QemuSwtpm=
can now be used withQemuFirmware=
set tolinux
or
bios
.- Added
UnitProperties=
to allow configure properties on the scopes
generated bysystemd-nspawn
andsystemd-run
. - mkosi now only builds a single default tools tree per build using the
settings from the last regular image that we'll build. - Configure scripts are now only executed for verbs which imply an image
build and are executed with the tools tree instead of without it. $QEMU_ARCHITECTURE
is now set for configure scripts to easily allow
scripts to figure out which qemu binary will be used to run qemu.- A file ID can now be specified for
QemuDrives=
. This allows adding
multiple qemu drives that are backed by the same file. - mkosi doesn't fail anymore if images already exist when running
mkosi build
. - Image names from
mkosi.images/
are now preferred over the specified
image ID when determining the output filename to use for an image. --include
now has a shorthand option-I
.- The
WITH_NETWORK
environment variable is now passed to build and
finalize scripts. - We now clamp mtimes to the specified source date epoch timestamp
instead of resetting all mtimes. This means that we won't touch any
mtimes that are already older than the given source date epoch
timestamp. - Removed support for CentOS 8 Stream as it is now EOL.
- The
coredumpctl
andjournalctl
verbs now operrate on the path
specified inForwardJournal=
if one is set. - Added
UnifiedKernelImageFormat=
format setting to allow configuring
the naming of unified kernel images generated by mkosi. - The
versionlock
plugin is now enabled by default for dnf with a noop
configuration. Repositories=
is now implemented for zypper.KernelModulesInclude=
andKernelModulesInitrdInclude=
now take the
special valueshost
anddefault
to include the host's loaded
modules and the default kernel modules defined inmkosi-initrd
respectively.KernelModulesIncludeHost=
andKernelModulesInitrdIncludeHost=
are
now deprecated.- Added
mkosi dependencies
to output the list of packages required by
mkosi to build and boot images.