mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-09-15 22:08:47 +00:00
osbuilder: ubuntu: Expose REPO_URL variables
This exposes REPO_URL and adds REPO_URL_X86_64 which can be set to use custom Ubuntu repo for building rootfs. If only one architecture is built, REPO_URL can be set. Otherwise, REPO_URL_X86_64 is used for x86_64 arch and REPO_URL for others. Fixes: #11276 Signed-off-by: Jacek Tomasiak <jtomasiak@arista.com> Signed-off-by: Jacek Tomasiak <jacek.tomasiak@gmail.com>
This commit is contained in:
@@ -56,6 +56,8 @@ GRACEFUL_EXIT=${GRACEFUL_EXIT:-""}
|
||||
USE_DOCKER=${USE_DOCKER:-""}
|
||||
USE_PODMAN=${USE_PODMAN:-""}
|
||||
EXTRA_PKGS=${EXTRA_PKGS:-""}
|
||||
REPO_URL=${REPO_URL:-""}
|
||||
REPO_URL_X86_64=${REPO_URL_X86_64:-""}
|
||||
|
||||
KBUILD_SIGN_PIN=${KBUILD_SIGN_PIN:-""}
|
||||
NVIDIA_GPU_STACK=${NVIDIA_GPU_STACK:-""}
|
||||
@@ -565,6 +567,8 @@ build_rootfs_distro()
|
||||
--env KERNEL_MODULES_DIR="${KERNEL_MODULES_DIR}" \
|
||||
--env LIBC="${LIBC}" \
|
||||
--env EXTRA_PKGS="${EXTRA_PKGS}" \
|
||||
--env REPO_URL="${REPO_URL}" \
|
||||
--env REPO_URL_X86_64="${REPO_URL_X86_64}" \
|
||||
--env OSBUILDER_VERSION="${OSBUILDER_VERSION}" \
|
||||
--env OS_VERSION="${OS_VERSION}" \
|
||||
--env VARIANT="${VARIANT}" \
|
||||
|
@@ -12,15 +12,15 @@ PACKAGES="chrony iptables dbus"
|
||||
[ "$AGENT_INIT" = no ] && PACKAGES+=" init"
|
||||
[ "$MEASURED_ROOTFS" = yes ] && PACKAGES+=" cryptsetup-bin e2fsprogs"
|
||||
[ "$SECCOMP" = yes ] && PACKAGES+=" libseccomp2"
|
||||
REPO_URL=http://ports.ubuntu.com
|
||||
|
||||
case "$ARCH" in
|
||||
aarch64) DEB_ARCH=arm64;;
|
||||
ppc64le) DEB_ARCH=ppc64el;;
|
||||
s390x) DEB_ARCH="$ARCH";;
|
||||
x86_64) DEB_ARCH=amd64; REPO_URL=http://archive.ubuntu.com/ubuntu;;
|
||||
x86_64) DEB_ARCH=amd64; REPO_URL=${REPO_URL_X86_64:-${REPO_URL:-http://archive.ubuntu.com/ubuntu}};;
|
||||
*) die "$ARCH not supported"
|
||||
esac
|
||||
REPO_URL=${REPO_URL:-http://ports.ubuntu.com}
|
||||
|
||||
if [ "$(uname -m)" != "$ARCH" ]; then
|
||||
case "$ARCH" in
|
||||
|
Reference in New Issue
Block a user