271954a41c
This adds support for a new `rpm-ostree compose extensions` command` which takes a treefile, a new extensions YAML file, and an OSTree repo and ref. It performs a depsolve and downloads the extensions to a provided output directory. This is intended to replace cosa's `download-extensions`: https://github.com/coreos/coreos-assembler/blob/master/src/download-extensions The input YAML schema matches the one accepted by that script. Some differences from the script: - We have a guaranteed depsolve match and thus can avoid silly issues we've hit in RHCOS (like downloading the wrong `libprotobuf` for `usbguard` -- rhbz#1889694). - We seamlessly re-use the same repos defined in the treefile, whereas the cosa script uses `reposdir=$dir` which doesn't have the same semantics (repo enablement is in that case purely based on the `enabled` flag in those repos, which may be different than what the rpm-ostree compose ran with). - We perform more sanity-checks against the requested extensions, such as whether the extension is already in the base. - We support no-change detection via a state SHA512 file for better integration in cosa and pipelines. - We support a `match-base-evr` key, which forces the extension to have the same EVR as the one from a base package: this is helpful in the case of extensions which complement a base package, esp. those which may not have strong enough reldeps to enforce matching EVRs by depsolve alone (`kernel-headers` is an example of this). - We don't try to organize the RPMs into separate directories by extension because IMO it's not at the right level. Instead, we should work towards higher-level metadata to represent extensions (see https://github.com/openshift/os/issues/409 which is related to this). Closes: #2055 |
||
---|---|---|
.. | ||
check | ||
common | ||
compose | ||
gpghome | ||
kolainst | ||
manual | ||
utils | ||
vmcheck | ||
compose.sh | ||
README.md | ||
runkola | ||
vmcheck.sh |
Tests are divided into three groups:
-
Tests in the
check
directory are non-destructive and uninstalled. Some of the tests require root privileges. Usemake check
to run these. -
The
composecheck
tests currently require uid 0 capabilities - the default in Docker, or you can run them via a user namespace. They are non-destructive, but are installed.To use them, you might do a
make && sudo make install
inside a Docker container.Then invoke
./tests/compose
. Alternatively of course, you can simply run the tests on a host system or in an existing container, without doing a build.Note: This is intentionally not a
Makefile
target because it doesn't require building and doesn't use uninstalled binaries. -
Tests in the
vmcheck
directory are oriented around using Vagrant. Usemake vmcheck
to run them. See alsoHACKING.md
in the top directory.
The common
directory contains files used by multiple
tests. The utils
directory contains helper utilities
required to run the tests.