Update to use versioned base images for CI. (#16053)
* Update to use versioned base images for CI. * Fix typos.
Austin S. Hemmelgarn committed
Sep 27, 2023 at 07:05 UTC
609e2c4accc86ce5279a1c0f445b1031176d9d13
5 files changed
+9
-8
.github/scripts/get-static-cache-key.sh
+3
-2
@@ -2,13 +2,14 @@
2
3
arch="${1}"
4
platform="$(packaging/makeself/uname2platform.sh "${arch}")"
5
+builder_rev="v1"
6
6
-docker pull --platform "${platform}" netdata/static-builder
7
+docker pull --platform "${platform}" netdata/static-builder:${builder_rev}
8
9
# shellcheck disable=SC2046
10
cat $(find packaging/makeself/jobs -type f ! -regex '.*\(netdata\|-makeself\).*') > /tmp/static-cache-key-data
11
11
-docker run -it --rm --platform "${platform}" netdata/static-builder sh -c 'apk list -I 2>/dev/null' >> /tmp/static-cache-key-data
12
+docker run -it --rm --platform "${platform}" netdata/static-builder:${builder_rev} sh -c 'apk list -I 2>/dev/null' >> /tmp/static-cache-key-data
13
14
h="$(sha256sum /tmp/static-cache-key-data | cut -f 1 -d ' ')"
15
.github/workflows/packaging.yml
+2
-2
@@ -228,14 +228,14 @@ jobs:
228
timeout_seconds: 900
229
command: |
230
docker pull --platform ${{ matrix.platform }} ${{ matrix.base_image }}
231
- docker pull --platform ${{ matrix.platform }} netdata/package-builders:${{ matrix.distro }}${{ matrix.version }}
231
+ docker pull --platform ${{ matrix.platform }} netdata/package-builders:${{ matrix.distro }}${{ matrix.version }}-v1
232
- name: Build Packages
233
id: build
234
if: needs.file-check.outputs.run == 'true'
235
shell: bash
236
run: |
237
docker run --security-opt seccomp=unconfined -e DISABLE_TELEMETRY=1 -e VERSION=${{ needs.version-check.outputs.version }} \
238
- --platform=${{ matrix.platform }} -v "$PWD":/netdata netdata/package-builders:${{ matrix.distro }}${{ matrix.version }}
238
+ --platform=${{ matrix.platform }} -v "$PWD":/netdata netdata/package-builders:${{ matrix.distro }}${{ matrix.version }}-v1
239
- name: Save Packages
240
id: artifacts
241
if: needs.file-check.outputs.run == 'true'
packaging/building-native-packages-locally.md
+1
-1
@@ -26,7 +26,7 @@ podman run -it --rm -e VERSION=0.1 -v $PWD:/netdata netdata/package-builders:<ta
26
27
The `<tag>` should be the lowercase distribution name with no spaces, followed by the
28
release of that distribution. For example, `centos7` to build on CentOS 7, or `ubuntu20.04`
29
-to build on Ubuntu 20.04. Note that we use Alma Linux for builds on CentOS/RHEL 8 or newer. See
29
+to build on Ubuntu 20.04. Note that we use Rocky Linux for builds on CentOS/RHEL 8 or newer. See
30
[netdata/package-builders](https://hub.docker.com/r/netdata/package-builders/tags) for all available tags.
31
32
The value passed in the `VERSION` environment variable can be any version number accepted by the type of package
packaging/docker/Dockerfile
+2
-2
@@ -3,7 +3,7 @@
3
4
# This image contains preinstalled dependencies
5
# hadolint ignore=DL3007
6
-FROM netdata/builder:latest as builder
6
+FROM netdata/builder:v1 as builder
7
8
# One of 'nightly' or 'stable'
9
ARG RELEASE_CHANNEL=nightly
@@ -59,7 +59,7 @@ RUN mkdir -p /app/usr/sbin/ \
59
#####################################################################
60
# This image contains preinstalled dependencies
61
# hadolint ignore=DL3007
62
-FROM netdata/base:latest as base
62
+FROM netdata/base:v1 as base
63
64
LABEL org.opencontainers.image.authors="Netdatabot <bot@netdata.cloud>"
65
LABEL org.opencontainers.image.url="https://netdata.cloud"
packaging/makeself/build-static.sh
+1
-1
@@ -24,7 +24,7 @@ else
24
exit 1
25
fi
26
27
-DOCKER_IMAGE_NAME="netdata/static-builder"
27
+DOCKER_IMAGE_NAME="netdata/static-builder:v1"
28
29
if [ "${BUILDARCH}" != "$(uname -m)" ] && [ "$(uname -m)" = 'x86_64' ] && [ -z "${SKIP_EMULATION}" ]; then
30
${docker} run --rm --privileged multiarch/qemu-user-static --reset -p yes || exit 1