Tweak the package building process
This commit is contained in:
parent
d28a0fc25e
commit
dc59cf894c
@ -4,8 +4,6 @@
|
|||||||
PATH="/usr/bin:/bin:/usr/sbin:/sbin"
|
PATH="/usr/bin:/bin:/usr/sbin:/sbin"
|
||||||
set -uxa
|
set -uxa
|
||||||
|
|
||||||
mapfile -t EMERGE_CALL_PARAMETERS <<< "${@}"
|
|
||||||
|
|
||||||
REGISTRY="${REGISTRY:-git.holgersson.xyz/gentoo-related/gentoo-binpkg-builder}"
|
REGISTRY="${REGISTRY:-git.holgersson.xyz/gentoo-related/gentoo-binpkg-builder}"
|
||||||
VERSION="${VERSION:-latest}"
|
VERSION="${VERSION:-latest}"
|
||||||
IMAGE_TAG="${REGISTRY}:${VERSION}"
|
IMAGE_TAG="${REGISTRY}:${VERSION}"
|
||||||
@ -31,6 +29,8 @@ podman_build_args=(
|
|||||||
-v "${PACKAGE_USE}:/etc/portage/package.use:ro"
|
-v "${PACKAGE_USE}:/etc/portage/package.use:ro"
|
||||||
# Share the gentoo repo, overlays etc.
|
# Share the gentoo repo, overlays etc.
|
||||||
-v "${REPOS}:/var/db/repos:ro"
|
-v "${REPOS}:/var/db/repos:ro"
|
||||||
|
# Share the world file, too.
|
||||||
|
-v "./world:/var/lib/portage/world:ro"
|
||||||
# Share the distfiles, i.e. typically source archives.
|
# Share the distfiles, i.e. typically source archives.
|
||||||
-v "${DISTFILES}:/var/cache/distfiles:rw,U"
|
-v "${DISTFILES}:/var/cache/distfiles:rw,U"
|
||||||
# Share the binpkgs r/w cache.
|
# Share the binpkgs r/w cache.
|
||||||
@ -45,6 +45,8 @@ mkdir -p "${BINPKG}"
|
|||||||
mkdir -p "${LOGDIR}"
|
mkdir -p "${LOGDIR}"
|
||||||
|
|
||||||
podman run "${podman_build_args[@]}" "${REGISTRY}:${VERSION}" \
|
podman run "${podman_build_args[@]}" "${REGISTRY}:${VERSION}" \
|
||||||
emerge --oneshot --keep-going ${EMERGE_CALL_PARAMETERS[@]}
|
bash -c "emerge --usepkg --newuse --keep-going --oneshot --deep --update @world \
|
||||||
|
&& emerge @golang-rebuild @rust-rebuild \
|
||||||
|
&& eclean-pkg --deep"
|
||||||
|
|
||||||
# vim:fileencoding=utf-8:ts=4:syntax=bash:expandtab
|
# vim:fileencoding=utf-8:ts=4:syntax=bash:expandtab
|
||||||
|
Reference in New Issue
Block a user