mirror of
https://github.com/containers/bootc.git
synced 2026-02-05 15:45:53 +01:00
This is aligning with what I did in https://github.com/ostreedev/ostree/pull/3439 - What gets invoked in e.g. GHA should ideally most be `just` commands that are easy to run locally too (with sudo in GHA, without sudo locally) - Move the "core build" to the toplevel so that one can just `podman build` directly too (without the Justfile) and have it do something useful - The "always build and test in a container" helps for LLM-assisted coding because what they can do is inherently sandboxed Signed-off-by: Colin Walters <walters@verbum.org>
22 lines
773 B
Docker
22 lines
773 B
Docker
# This injects some extra testing stuff into our image
|
|
|
|
FROM scratch as context
|
|
# We only need this stuff in the initial context
|
|
COPY hack /hack
|
|
COPY contrib /contrib
|
|
|
|
FROM localhost/bootc
|
|
# We support e.g. adding cloud-init
|
|
ARG variant=
|
|
# And this layer has additional stuff for testing, such as nushell etc.
|
|
RUN --mount=type=bind,from=context,target=/run/context <<EORUN
|
|
set -xeuo pipefail
|
|
/run/context/hack/provision-derived.sh "$variant"
|
|
# Add some testing kargs into our dev builds
|
|
install -D -t /usr/lib/bootc/kargs.d /run/context/hack/test-kargs/*
|
|
# Also copy in some default install configs we use for testing
|
|
install -D -t /usr/lib/bootc/install/ /run/context/hack/install-test-configs/*
|
|
# Finally, test our own linting
|
|
bootc container lint --fatal-warnings
|
|
EORUN
|