@@ -28,7 +28,7 @@ stages:
tags:
- x86_64
variables:
- CONTAINER: alpine:x86_64-build
+ CONTAINER: alpine:3.18-x86_64-build
#
# ARM64 artifacts
@@ -62,7 +62,7 @@ x86_64-rootfs-alpine-3.18:
script:
- . scripts/x86_64-rootfs-alpine.sh
variables:
- CONTAINER: alpine:x86_64-rootfs
+ CONTAINER: alpine:3.18-x86_64-base
x86_64-argo-linux-6.6.56:
extends: .x86_64-artifacts
@@ -25,8 +25,8 @@ die() {
BASE="registry.gitlab.com/xen-project/hardware/test-artifacts"
case "_${CONTAINER}" in
_alpine-3.18-arm64-build) CONTAINER="${BASE}/alpine:3.18-arm64-build" ;;
- _alpine-x86_64-rootfs) CONTAINER="${BASE}/alpine:x86_64-rootfs" ;;
- _alpine-x86_64-build|_) CONTAINER="${BASE}/alpine:x86_64-build" ;;
+ _alpine-3.18-x86_64-base) CONTAINER="${BASE}/alpine:3.18-x86_64-base" ;;
+ _alpine-3.18-x86_64-build|_) CONTAINER="${BASE}/alpine:3.18-x86_64-build" ;;
esac
# Use this variable to control whether root should be used
new file mode 100644
@@ -0,0 +1,6 @@
+# syntax=docker/dockerfile:1
+FROM --platform=linux/amd64 alpine:3.18
+LABEL maintainer.name="The Xen Project"
+LABEL maintainer.email="xen-devel@lists.xenproject.org"
+
+RUN apk --no-cache add bash
similarity index 54%
rename from images/alpine/x86_64-build.dockerfile
rename to images/alpine/3.18-x86_64-build.dockerfile
@@ -1,31 +1,39 @@
# syntax=docker/dockerfile:1
FROM --platform=linux/amd64 alpine:3.18
-LABEL maintainer.name="The Xen Project" \
- maintainer.email="xen-devel@lists.xenproject.org"
+LABEL maintainer.name="The Xen Project"
+LABEL maintainer.email="xen-devel@lists.xenproject.org"
RUN apk --no-cache add bash
-RUN bash -ex <<EOF
+RUN <<EOF
+#!/bin/bash
+ set -eu
+
adduser -D user --shell /bin/bash
- DEPS=(
- musl-dev
+ DEPS=(# Base environment
build-base
- libc6-compat
- linux-headers
- bash
- git
curl
- flex
+ git
+
+ # Linux build deps
bison
+ diffutils
elfutils-dev
+ findutils
+ flex
+ gawk
+ linux-headers
+ openssl-dev
+ perl
+
+ # Argo build deps
autoconf
automake
libtool
- openssl-dev
)
- apk add --no-cache "\${DEPS[@]}"
+ apk add --no-cache "${DEPS[@]}"
EOF
USER user
deleted file mode 100644
@@ -1,4 +0,0 @@
-# syntax=docker/dockerfile:1
-FROM --platform=linux/amd64 alpine:3.18
-LABEL maintainer.name="The Xen Project" \
- maintainer.email="xen-devel@lists.xenproject.org"
Insert the Alpine version as we'll need a newer version in due course, and rename 'rootfs' to 'base' as the container really is not a rootfs on it's own. In base, add bash. It's added later by the rootfs generation anyway, but this way we can write the generation script in bash too. In build, group and sort the packages. Drop the ones we don't need, or are pulled in by dependencies. Include diffutils, findutils and gawk to avoid warnings in the kernel build. Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> --- CC: Anthony PERARD <anthony.perard@vates.tech> CC: Stefano Stabellini <sstabellini@kernel.org> CC: Michal Orzel <michal.orzel@amd.com> CC: Doug Goldstein <cardoe@cardoe.com> CC: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com> CC: Jason Andryuk <jason.andryuk@amd.com> CC: Daniel P. Smith <dpsmith@apertussolutions.com> --- .gitlab-ci.yml | 4 +-- containerize | 4 +-- images/alpine/3.18-x86_64-base.dockerfile | 6 ++++ ...ockerfile => 3.18-x86_64-build.dockerfile} | 32 ++++++++++++------- images/alpine/x86_64-rootfs.dockerfile | 4 --- 5 files changed, 30 insertions(+), 20 deletions(-) create mode 100644 images/alpine/3.18-x86_64-base.dockerfile rename images/alpine/{x86_64-build.dockerfile => 3.18-x86_64-build.dockerfile} (54%) delete mode 100644 images/alpine/x86_64-rootfs.dockerfile