Skip to content

Commit 8549db6

Browse files
committed
cmd-build-with-buildah: retain overrides/ API functionality
`build-rootfs` in f-c-c learned a new `overrides/` API that matches how it works in cosa. Use that API to proxy through the cosa workdir `overrides/` dir.
1 parent 6ad72d2 commit 8549db6

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/cmd-build-with-buildah

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,13 @@ build_with_buildah() {
133133
-v /etc/pki/ca-trust:/etc/pki/ca-trust:ro
134134
fi
135135

136+
if [ -d overrides ]; then
137+
if [[ -n $(ls overrides/rpm/*.rpm 2> /dev/null) ]]; then
138+
(cd overrides/rpm && rm -rf .repodata && createrepo_c .)
139+
fi
140+
set -- "$@" -v "$(realpath overrides)":/run/src/overrides
141+
fi
142+
136143
if [ -n "$DIRECT" ]; then
137144
# turn on layer caching in the direct case; it wouldn't hurt in the
138145
# supermin path, but it'd be a waste of space on the rootfs

0 commit comments

Comments
 (0)