This commit extends the bootstrap macro management to also consider
the case where image was already bootstrap. Note this is a common case
for building derived container images and also the situation when
`--allow-existing-root` flag is in use.
There are rpm versions that require access to /dev and fail
with the error message 'Failed to initialize NSS library'
For details see: https://bugs.centos.org/view.php?id=14767
Due to the rpm location checkup fix from Issue #1037 this
change impacts builds for distributions that uses an rpm
version with the above behavior (e.g CentOS) and fails as
consequence of the rpm call error. This commit fixes this
in a way that we make sure the host /dev is available at
the time of the call.
The motivation is nice to check if the required grub module
package is part of the package list if the efi firmware is
requested, but as long as there is no distribution wide
standard for packaging grub this check will cause more trouble
than it is of help. Currently it failed for the arm architecture
and the grub2-arm64-efi package. We decided to prevent checking
against static lists and dropped this runtime check. Missing
grub modules will be recognized at the grub stage when we
search for them.
There is no further demand in the client config creation for the
legacy netboot code. Customers using the netboot initrd already
create the client config.<MAC> file manually or through another
system. With the next generation kiwi we also recommend the disk
based network deployment using the dracut capabilities and marked
the netboot code as still supported but on the legacy stream.
Along with the deletion in the schema the following changes
were also done:
* Deleted use of pxedeploy section in implementation
* Increase schema version to v7.0
* Update documentation on schema version update
* Added xsl stylesheet conversion from v6.9 to v7.0
Automatic schema version upgrade from v6.9 to v7.0 deletes
the pxedeploy section from any type specification
This Fixes#19
This commit adds runtime configuration parameters to disable the runtime
checks. This is specially handy if someone does not want to use the kiwi
dracut modules and provide custom ones instead. In orde disable some
runtime check consider a runtime config yaml like:
runtime_checks:
- disable:
- check_dracut_module_for_oem_install_in_package_list
- check_dracut_module_for_live_iso_in_package_list
This commit fixes#893
In case of a qcow2 format we store the result uncompressed
Since the format conversion only takes the real bytes into
account such that the sparseness of the raw disk will not
result in the output format and can be taken one by one
This Fixes bsc#1128146
In addition the commit includes a refactoring for the
evaluation of the compress flag in the runtime config.
Instead of the global overwrite, the flag gets evaluated
individually at the time the result metadata is created
The method checked for the presence of /usr/bin/rpm. But
that binary is also provided by another toolkit named
busybox. Thus to check if the rpm we are aiming for is
present the check has been modified to look for /usr/bin/rpmdb
which is exclusively provided by rpm only. This Fixes#1037
At the end of a build process the metadata information files .packages
and .verified are created. On rpm based systems, rpm is invoked as
chrooted operation inside the new root tree. For images that gets
installed exclusively from the bootstrap phase there is no rpm inside
of the image and the call fails. The result are empty metadata files.
This patch prevents calling rpm inside of the image root tree if it's
not installed and also uses the RpmDataBase interface instead of
directly calling rpm. This Fixes#1037
This commit adds buildah tool support for OCI and Docker types. It
requires buildah and skopeo to be installed in the host. The use of
umoci (kept as default choice) or buildah is configured using the
runtime configuration file; consider the following structure:
```
oci:
- archive_tool: buildah
```
Image descriptions that define packages in the bootstrap section
only don't need a package manager inside of the image. However
the code to update the location of the rpm database did not
check the presence of rpm and failed on such image descriptions.
This Fixes#1030
Currently we call scripts directly through bash, which has the unfortunate
disadvantage, that the shebang line is completely ignored.
Now we instead check whether the owner of the script is allowed to execute it
and if yes, we let the OS execute it (which takes the shebang into account) or
otherwise call it through bash.
This function calls os.access, but first checks whether the input parameters are
sane, instead of simply returning false when the file in question does not exist
or an invalid mode was specified.
In addition to the support for fstab.append, users can now also
provide a patch file to change the contents of the fstab file
as it got written by kiwi. The feature is probably rarely used
but needed in the area of suse's transactional update mechanism.
This Fixes bsc#1129566 and Fixes#945
The documentation is suggesting that rsync is used by default to synchronize the
shared folders, yet the libvirt vagrant boxes used the system default (=nfs).
The root of the live ISO has permissions 0700, which is inconvenient if
you mount it to explore its contents. Relax to 0755 instead.
Without this, the mounted ISO FS can only be accessed by root.
This commit refactors the OCI images support:
* added import_container_image and export_container_image methods
to oci_tools classes. 'umoci' and 'buildah' consume different
formats thus the inital skopeo call to import a container is tool
dependent.
* use oci-archive transport for packing the OCI images, this causes
docker and oci operations to just diverge on transport type.
* add_tag method no longer needed in oci_tools/base, skopeo is used
for that matter.
* container/docker.py class is no longer needed. The difference
between docker and OCI images is just on packing format which is just
a parameter in skopeo. It does not deserve a dedicated class
* system/root_import/docker.py class no longer needed. The difference
between OCI and Docker class was just the transport type for the
skopeo call. It does not deserve a dedicated class
The dnf.conf file generated by KIWI contained some obsolete
options as well as options that have been renamed.
This change updates the options set so that they match what
is expected by DNF and configures the appropriate behavior.
Added runtime check check_volume_setup_defines_multiple_fullsize_volumes
which reads the volume setup and counts the number of volumes that
define a 'all' volume. Only one is allowed
If there is no mkisofs/genisoimage present on the system, the
tests based on real example iso files are skipped. The code
tested in this case is now covered in a mock style to run
through the logic even without the tools in place
Move the code handling the compat setup of the rpm database
to the correct method of the repository API. Call the
import of the signing keys only if there are signing
keys
This commits adds initial support to build Vagrant boxes with the Virtualbox
provider.
- The attribute 'provider' of the option <vagrantconfig> now supports the option
"virtualbox".
- A new boolean attribute 'virtualbox_guest_additions_present' was added to
<vagrantconfig>. When set to true, KIWI will assume that guest additions have
been installed into the base image and configure the shared folders to use
vboxfs, otherwise rsync will be used.
This fixes#532 (https://github.com/SUSE/kiwi/issues/532).
YUM v3 is no longer developed, having been superseded by DNF for
several years. With DNF now available as a usable package manager
in Red Hat Enterprise Linux 7 through the Extras channel and
SUSE Linux Enterprise 15 through PackageHub, there is no reason for
keeping support for YUM v3 around.
We are keeping support for requesting YUM because in Red Hat Enterprise
Linux 7, DNF is referred to as "YUM v4", and it is simply referred to
as "YUM" in Red Hat Enterprise Linux 8. To avoid confusion from people,
we're just going to leave it in place as an alias to the DNF package
manager.
As for why this is happening now, Fedora is retiring YUM v3 in
Fedora 31, so we might as well get it over with and cut over now.
Reference: https://fedoraproject.org/wiki/Changes/Retire_YUM_3
In reference to bsc#1112357 it was required to add the compat
symlink /var/lib/rpm such that zypper can read the signing
keys. Unfortunately zypper does not use the configured rpmdb
from the rpm macro setup.
util-linux dropped losetup-Add-support-for-setting-logical-blocksize.patch
because different implementations exists in the new kernel, and it has
a conflicting implementation in util-linux. This caused a change in the
option to specify the logical sector size. The option --logical-blocksize
was replaced by --sector-size. We adapt this now in kiwi too
In preparation to support other vagrant providers a base class
for Vagrant operations has been created. Original Code written
by DanČermák <dcermak@suse.com>
In case isolinux-config failed or does not exist on the
distribution a fallback path is called. That code hardlinks
the files to the isolinux compiled in standard path. However
due to the move of the grub unicode file for iso images
the path contains a directory. Directories can't be hardlinked
thus this patch uses 'cp -l' instead of the 'ln' command to
create the linked target contents.
This is a follow up patch for #f5bac4495d34. The change of the
location of the font file was not applied if an iso target, live
or install image is being built. This patch completes the change
and Fixes bsc#1124885
In the preferences section the following optional subsection
can be configured:
<rpm-locale-filtering>true|false</rpm-locale-filtering>
If set to true the default locales POSIX, C, and C.UTF-8 are
applied as rpm install_lang macro. If the locale section is
configured in addition the list is extended by that information
too
For rpm based builds the License field from the rpm metadata
is extracted into the .packages file. For Debian based build
the license information is in an extra file and not taken
into account for the moment.
During the image build the custom rpm macro %_install_langs
is configured with the <locale> setup from the KIWI XML
description. This allows to filter language specific packages
on the rpm level and Fixes#771
Allow to validate the return code from a package manager
operation. In case of zypper the standard UNIX return
code validation does not apply. Return codes from zypper
which are >= 100 are not treated as an error anymore