* [PR PATCH] common/container: move masterdir image building to void-packages
@ 2023-07-30 5:31 classabbyamp
2023-08-12 19:49 ` [PR PATCH] [Updated] " classabbyamp
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: classabbyamp @ 2023-07-30 5:31 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 856 bytes --]
There is a new pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages build-root-image
https://github.com/void-linux/void-packages/pull/45320
common/container: move masterdir image building to void-packages
see void-linux/void-docker#11
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
- need to test in CI still
before:
```
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64 607MB
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64-musl 522MB
```
after:
```
localhost:5000/void-build-root-glibc latest 438MB
localhost:5000/void-build-root-musl latest 383MB
```
A patch file from https://github.com/void-linux/void-packages/pull/45320.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-root-image-45320.patch --]
[-- Type: text/x-diff, Size: 7502 bytes --]
From a6603efbc27198c06ce1d456400e8bfec3e98c1c Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sun, 30 Jul 2023 01:00:16 -0400
Subject: [PATCH] common/container: move masterdir image building to
void-packages
see void-linux/void-docker#11
---
.dockerignore | 3 ++
.github/workflows/container.yaml | 64 ++++++++++++++++++++++++++++++++
common/container/Containerfile | 34 +++++++++++++++++
common/container/docker-bake.hcl | 37 ++++++++++++++++++
| 13 +++++++
common/container/setup.sh | 29 +++++++++++++++
6 files changed, 180 insertions(+)
create mode 100644 .dockerignore
create mode 100644 .github/workflows/container.yaml
create mode 100644 common/container/Containerfile
create mode 100644 common/container/docker-bake.hcl
create mode 100644 common/container/noextract.conf
create mode 100644 common/container/setup.sh
diff --git a/.dockerignore b/.dockerignore
new file mode 100644
index 0000000000000..2d28584d8dbfb
--- /dev/null
+++ b/.dockerignore
@@ -0,0 +1,3 @@
+*
+!common/container/
+!common/repo-keys/
diff --git a/.github/workflows/container.yaml b/.github/workflows/container.yaml
new file mode 100644
index 0000000000000..3b55629a85578
--- /dev/null
+++ b/.github/workflows/container.yaml
@@ -0,0 +1,64 @@
+---
+name: 'Build build-root containers'
+
+on:
+ workflow_dispatch:
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ outputs:
+ metadata: ${{ steps.build_and_push.outputs.metadata }}
+ steps:
+ - name: Checkout
+ uses: classabbyamp/treeless-checkout-action@v1
+
+ - name: Docker metadata
+ id: meta
+ uses: docker/metadata-action@v4
+ with:
+ images: |
+ ghcr.io/${{ github.repository_owner }}/void-build-root-glibc
+ ghcr.io/${{ github.repository_owner }}/void-build-root-musl
+ tags: |
+ type=sha,prefix=
+ type=raw,value=latest,enable={{is_default_branch}}
+ type=raw,value={{date 'YYYYMMDD'}},enable={{is_default_branch}},priority=1000
+ flavor: latest=false
+ labels: |
+ org.opencontainers.image.authors=Void Linux team and contributors
+ org.opencontainers.image.url=https://voidlinux.org
+ org.opencontainers.image.documentation=https://github.com/${{ github.repository }}
+ org.opencontainers.image.source=https://github.com/${{ github.repository }}
+ org.opencontainers.image.vendor=Void Linux
+ org.opencontainers.image.title=Void Linux build root
+ org.opencontainers.image.description=Image for building packages with xbps-src on Void Linux
+
+ - name: Set up QEMU
+ uses: docker/setup-qemu-action@v2
+
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v2
+
+ - name: Login to GCHR
+ uses: docker/login-action@v2
+ with:
+ registry: ghcr.io
+ username: ${{ github.actor }}
+ password: ${{ secrets.GITHUB_TOKEN }}
+
+ - name: Build and push images
+ id: build_and_push
+ uses: docker/bake-action@v3
+ with:
+ push: ${{ endsWith(github.ref, 'master') }}
+ files: |
+ common/container/docker-bake.hcl
+ ${{ steps.meta.outputs.bake-file }}
+ set: |
+ _common.cache-to=type=gha
+ _common.cache-from=type=gha
diff --git a/common/container/Containerfile b/common/container/Containerfile
new file mode 100644
index 0000000000000..008aab15eea83
--- /dev/null
+++ b/common/container/Containerfile
@@ -0,0 +1,34 @@
+# syntax=docker/dockerfile:1
+FROM --platform=${BUILDPLATFORM} alpine:3.18 AS bootstrap
+ARG TARGETPLATFORM
+ARG MIRROR=https://repo-ci.voidlinux.org
+ARG LIBC
+RUN apk add ca-certificates curl && \
+ curl "${MIRROR}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz" | tar vJx
+COPY common/repo-keys/* /target/var/db/xbps/keys/
+COPY common/container/setup.sh /bootstrap/setup.sh
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -S \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target
+
+FROM --platform=${BUILDPLATFORM} bootstrap AS install
+ARG TARGETPLATFORM
+ARG MIRROR
+ARG LIBC
+COPY --from=bootstrap /target /target
+COPY common/container/noextract.conf /target/etc/xbps.d/noextract.conf
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -y \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target \
+ base-chroot void-repo-bootstrap
+
+FROM scratch AS image
+COPY --link --from=install /target /
+RUN --mount=type=tmpfs,target=/tmp \
+ xbps-reconfigure -a; \
+ rm -rf /var/cache/xbps/*
+CMD ["/bin/sh"]
diff --git a/common/container/docker-bake.hcl b/common/container/docker-bake.hcl
new file mode 100644
index 0000000000000..375b34393625a
--- /dev/null
+++ b/common/container/docker-bake.hcl
@@ -0,0 +1,37 @@
+variable "MIRROR" {
+ default = "https://repo-ci.voidlinux.org/"
+}
+
+target "docker-metadata-action" {}
+
+target "_common" {
+ inherits = ["docker-metadata-action"]
+ dockerfile = "common/container/Containerfile"
+ no-cache-filter = ["bootstrap"]
+ cache-to = ["type=local,dest=/tmp/buildx-cache"]
+ cache-from = ["type=local,src=/tmp/buildx-cache"]
+ target = "image"
+ args = {
+ "MIRROR" = "${MIRROR}"
+ }
+}
+
+target "void-build-root-glibc" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/386", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "glibc" }
+}
+
+target "void-build-root-musl" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "musl" }
+}
+
+group "default" {
+ targets = [
+ "void-build-root-glibc",
+ "void-build-root-musl",
+ ]
+}
+
--git a/common/container/noextract.conf b/common/container/noextract.conf
new file mode 100644
index 0000000000000..be8ac91510c5e
--- /dev/null
+++ b/common/container/noextract.conf
@@ -0,0 +1,13 @@
+noextract=/etc/sv*
+noextract=/usr/share/man*
+noextract=/usr/lib/dracut*
+noextract=/etc/skel*
+noextract=/usr/lib/modprobe.d*
+noextract=/usr/lib/sysctl.d*
+noextract=/usr/lib/udev*
+noextract=/usr/share/bash-completion*
+noextract=/usr/share/fish/vendor-completions.d*
+noextract=/usr/share/zsh/site-functions*
+noextract=/usr/share/info*
+noextract=/usr/share/locale*
+noextract=/usr/lib/gconv*
diff --git a/common/container/setup.sh b/common/container/setup.sh
new file mode 100644
index 0000000000000..f28a2b2073c64
--- /dev/null
+++ b/common/container/setup.sh
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+: "${MIRROR:=https://repo-default.voidlinux.org/}"
+
+suffix() {
+ case "${LIBC:?}" in
+ musl) echo "-musl" ;;
+ esac
+}
+
+repo() {
+ case "${ARCH:?}" in
+ aarch64*) echo "${MIRROR}/current/aarch64" ;;
+ *-musl) echo "${MIRROR}/current/musl" ;;
+ *) echo "${MIRROR}/current" ;;
+ esac
+}
+
+case "${TARGETPLATFORM:?}" in
+linux/arm/v6) ARCH="armv6l$(suffix)" ;;
+linux/arm/v7) ARCH="armv7l$(suffix)" ;;
+linux/arm64) ARCH="aarch64$(suffix)" ;;
+linux/amd64) ARCH="x86_64$(suffix)" ;;
+linux/386) ARCH="i686$(suffix)" ;;
+esac
+
+REPO="$(repo)"
+
+export ARCH REPO
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PR PATCH] [Updated] common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
@ 2023-08-12 19:49 ` classabbyamp
2023-08-12 21:06 ` classabbyamp
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-12 19:49 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 861 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages build-root-image
https://github.com/void-linux/void-packages/pull/45320
common/container: move masterdir image building to void-packages
see void-linux/void-docker#11
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
- need to test in CI still
before:
```
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64 607MB
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64-musl 522MB
```
after:
```
localhost:5000/void-build-root-glibc latest 438MB
localhost:5000/void-build-root-musl latest 383MB
```
A patch file from https://github.com/void-linux/void-packages/pull/45320.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-root-image-45320.patch --]
[-- Type: text/x-diff, Size: 7600 bytes --]
From 0326071a71433ec3b235d6089350c29d8ec0fe39 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sun, 30 Jul 2023 01:00:16 -0400
Subject: [PATCH] common/container: move masterdir image building to
void-packages
see void-linux/void-docker#11
---
.dockerignore | 3 ++
.github/workflows/container.yaml | 78 ++++++++++++++++++++++++++++++++
common/container/Containerfile | 35 ++++++++++++++
common/container/docker-bake.hcl | 29 ++++++++++++
| 13 ++++++
common/container/setup.sh | 29 ++++++++++++
6 files changed, 187 insertions(+)
create mode 100644 .dockerignore
create mode 100644 .github/workflows/container.yaml
create mode 100644 common/container/Containerfile
create mode 100644 common/container/docker-bake.hcl
create mode 100644 common/container/noextract.conf
create mode 100644 common/container/setup.sh
diff --git a/.dockerignore b/.dockerignore
new file mode 100644
index 0000000000000..2d28584d8dbfb
--- /dev/null
+++ b/.dockerignore
@@ -0,0 +1,3 @@
+*
+!common/container/
+!common/repo-keys/
diff --git a/.github/workflows/container.yaml b/.github/workflows/container.yaml
new file mode 100644
index 0000000000000..b4708fb07b9f8
--- /dev/null
+++ b/.github/workflows/container.yaml
@@ -0,0 +1,78 @@
+---
+name: 'Build buildroot containers'
+
+on:
+ workflow_dispatch:
+ pull_request:
+ branches:
+ - master
+ paths:
+ - common/container/**
+ push:
+ branches:
+ - master
+ paths:
+ - common/container/**
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ libc:
+ - glibc
+ - musl
+ steps:
+ - name: Checkout
+ uses: classabbyamp/treeless-checkout-action@v1
+
+ - name: Docker metadata
+ id: meta
+ uses: docker/metadata-action@v4
+ with:
+ images: |
+ ghcr.io/${{ github.repository_owner }}/void-buildroot-${{ matrix.libc }}
+ tags: |
+ type=sha,prefix=
+ type=raw,value=latest,enable={{is_default_branch}}
+ type=raw,value={{date 'YYYYMMDD'}},enable={{is_default_branch}},priority=1000
+ flavor: latest=false
+ labels: |
+ org.opencontainers.image.authors=Void Linux team and contributors
+ org.opencontainers.image.url=https://voidlinux.org
+ org.opencontainers.image.documentation=https://github.com/${{ github.repository }}
+ org.opencontainers.image.source=https://github.com/${{ github.repository }}
+ org.opencontainers.image.vendor=Void Linux
+ org.opencontainers.image.title=Void Linux build root
+ org.opencontainers.image.description=Image for building packages with xbps-src on Void Linux
+
+ - name: Set up QEMU
+ uses: docker/setup-qemu-action@v2
+
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v2
+
+ - name: Login to GCHR
+ if: github.event_name != 'pull_request'
+ uses: docker/login-action@v2
+ with:
+ registry: ghcr.io
+ username: ${{ github.actor }}
+ password: ${{ secrets.GITHUB_TOKEN }}
+
+ - name: Build and push images
+ id: build_and_push
+ uses: docker/bake-action@v3
+ with:
+ push: ${{ github.event_name != 'pull_request' }}
+ targets: void-buildroot-${{ matrix.libc }}
+ files: |
+ common/container/docker-bake.hcl
+ ${{ steps.meta.outputs.bake-file }}
+ set: |
+ _common.cache-to=type=gha
+ _common.cache-from=type=gha
diff --git a/common/container/Containerfile b/common/container/Containerfile
new file mode 100644
index 0000000000000..6b5478cb6a3af
--- /dev/null
+++ b/common/container/Containerfile
@@ -0,0 +1,35 @@
+# syntax=docker/dockerfile:1
+FROM --platform=${BUILDPLATFORM} alpine:3.18 AS bootstrap
+ARG TARGETPLATFORM
+ARG MIRROR=https://repo-ci.voidlinux.org
+ARG LIBC
+RUN apk add ca-certificates curl && \
+ curl "${MIRROR}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz" | tar vJx
+COPY common/repo-keys/* /target/var/db/xbps/keys/
+COPY common/container/setup.sh /bootstrap/setup.sh
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -S \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target
+
+FROM --platform=${BUILDPLATFORM} bootstrap AS install
+ARG TARGETPLATFORM
+ARG MIRROR
+ARG LIBC
+COPY --from=bootstrap /target /target
+COPY common/container/noextract.conf /target/etc/xbps.d/noextract.conf
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -y \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target \
+ base-chroot void-repo-bootstrap
+
+FROM scratch AS image
+COPY --link --from=install /target /
+RUN \
+ install -dm1777 tmp; \
+ xbps-reconfigure -fa; \
+ rm -rf /var/cache/xbps/*
+CMD ["/bin/sh"]
diff --git a/common/container/docker-bake.hcl b/common/container/docker-bake.hcl
new file mode 100644
index 0000000000000..f290206f89e6a
--- /dev/null
+++ b/common/container/docker-bake.hcl
@@ -0,0 +1,29 @@
+variable "MIRROR" {
+ default = "https://repo-ci.voidlinux.org/"
+}
+
+target "docker-metadata-action" {}
+
+target "_common" {
+ inherits = ["docker-metadata-action"]
+ dockerfile = "common/container/Containerfile"
+ no-cache-filter = ["bootstrap"]
+ cache-to = ["type=local,dest=/tmp/buildx-cache"]
+ cache-from = ["type=local,src=/tmp/buildx-cache"]
+ target = "image"
+ args = {
+ "MIRROR" = "${MIRROR}"
+ }
+}
+
+target "void-buildroot-glibc" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/386", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "glibc" }
+}
+
+target "void-buildroot-musl" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "musl" }
+}
--git a/common/container/noextract.conf b/common/container/noextract.conf
new file mode 100644
index 0000000000000..be8ac91510c5e
--- /dev/null
+++ b/common/container/noextract.conf
@@ -0,0 +1,13 @@
+noextract=/etc/sv*
+noextract=/usr/share/man*
+noextract=/usr/lib/dracut*
+noextract=/etc/skel*
+noextract=/usr/lib/modprobe.d*
+noextract=/usr/lib/sysctl.d*
+noextract=/usr/lib/udev*
+noextract=/usr/share/bash-completion*
+noextract=/usr/share/fish/vendor-completions.d*
+noextract=/usr/share/zsh/site-functions*
+noextract=/usr/share/info*
+noextract=/usr/share/locale*
+noextract=/usr/lib/gconv*
diff --git a/common/container/setup.sh b/common/container/setup.sh
new file mode 100644
index 0000000000000..f28a2b2073c64
--- /dev/null
+++ b/common/container/setup.sh
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+: "${MIRROR:=https://repo-default.voidlinux.org/}"
+
+suffix() {
+ case "${LIBC:?}" in
+ musl) echo "-musl" ;;
+ esac
+}
+
+repo() {
+ case "${ARCH:?}" in
+ aarch64*) echo "${MIRROR}/current/aarch64" ;;
+ *-musl) echo "${MIRROR}/current/musl" ;;
+ *) echo "${MIRROR}/current" ;;
+ esac
+}
+
+case "${TARGETPLATFORM:?}" in
+linux/arm/v6) ARCH="armv6l$(suffix)" ;;
+linux/arm/v7) ARCH="armv7l$(suffix)" ;;
+linux/arm64) ARCH="aarch64$(suffix)" ;;
+linux/amd64) ARCH="x86_64$(suffix)" ;;
+linux/386) ARCH="i686$(suffix)" ;;
+esac
+
+REPO="$(repo)"
+
+export ARCH REPO
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
2023-08-12 19:49 ` [PR PATCH] [Updated] " classabbyamp
@ 2023-08-12 21:06 ` classabbyamp
2023-08-12 21:06 ` classabbyamp
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-12 21:06 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 256 bytes --]
New comment by classabbyamp on void-packages repository
https://github.com/void-linux/void-packages/pull/45320#issuecomment-1676100080
Comment:
I will not merge this directly, but instead in 2 stages, 1 to build the new images, 1 to update the workflows
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
2023-08-12 19:49 ` [PR PATCH] [Updated] " classabbyamp
2023-08-12 21:06 ` classabbyamp
@ 2023-08-12 21:06 ` classabbyamp
2023-08-12 21:07 ` [PR PATCH] [Updated] " classabbyamp
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-12 21:06 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 256 bytes --]
New comment by classabbyamp on void-packages repository
https://github.com/void-linux/void-packages/pull/45320#issuecomment-1676100080
Comment:
I will not merge this directly, but instead in 2 stages: 1 to build the new images, 1 to update the workflows
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PR PATCH] [Updated] common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
` (2 preceding siblings ...)
2023-08-12 21:06 ` classabbyamp
@ 2023-08-12 21:07 ` classabbyamp
2023-08-18 19:59 ` classabbyamp
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-12 21:07 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 933 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages build-root-image
https://github.com/void-linux/void-packages/pull/45320
common/container: move masterdir image building to void-packages
see void-linux/void-docker#11
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
- example run: https://github.com/classabbyamp/void-packages/actions/runs/5843401357
before:
```
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64 607MB
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64-musl 522MB
```
after:
```
localhost:5000/void-buildroot-glibc latest 438MB
localhost:5000/void-buildroot-musl latest 383MB
```
A patch file from https://github.com/void-linux/void-packages/pull/45320.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-root-image-45320.patch --]
[-- Type: text/x-diff, Size: 10793 bytes --]
From d0d15f426edb6bfcd71eca364c8c23d2f008aad4 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sun, 30 Jul 2023 01:00:16 -0400
Subject: [PATCH 1/2] common/container: move masterdir image building to
void-packages
see void-linux/void-docker#11
---
.dockerignore | 3 ++
.github/workflows/container.yaml | 84 ++++++++++++++++++++++++++++++++
common/container/Containerfile | 35 +++++++++++++
common/container/docker-bake.hcl | 29 +++++++++++
| 13 +++++
common/container/setup.sh | 29 +++++++++++
6 files changed, 193 insertions(+)
create mode 100644 .dockerignore
create mode 100644 .github/workflows/container.yaml
create mode 100644 common/container/Containerfile
create mode 100644 common/container/docker-bake.hcl
create mode 100644 common/container/noextract.conf
create mode 100644 common/container/setup.sh
diff --git a/.dockerignore b/.dockerignore
new file mode 100644
index 0000000000000..2d28584d8dbfb
--- /dev/null
+++ b/.dockerignore
@@ -0,0 +1,3 @@
+*
+!common/container/
+!common/repo-keys/
diff --git a/.github/workflows/container.yaml b/.github/workflows/container.yaml
new file mode 100644
index 0000000000000..6d6d69195ec32
--- /dev/null
+++ b/.github/workflows/container.yaml
@@ -0,0 +1,84 @@
+---
+name: 'Build buildroot containers'
+
+on:
+ workflow_dispatch:
+ pull_request:
+ branches:
+ - master
+ paths:
+ - common/container/**
+ push:
+ branches:
+ - master
+ paths:
+ - common/container/**
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+
+ permissions:
+ contents: read
+ packages: write
+
+ strategy:
+ matrix:
+ libc:
+ - glibc
+ - musl
+
+ steps:
+ - name: Checkout
+ uses: classabbyamp/treeless-checkout-action@v1
+
+ - name: Docker metadata
+ id: meta
+ uses: docker/metadata-action@v4
+ with:
+ images: |
+ ghcr.io/${{ github.repository_owner }}/void-buildroot-${{ matrix.libc }}
+ tags: |
+ type=sha,prefix=
+ type=raw,value=latest,enable={{is_default_branch}}
+ type=raw,value={{date 'YYYYMMDD'}},enable={{is_default_branch}},priority=1000
+ flavor: latest=false
+ labels: |
+ org.opencontainers.image.authors=Void Linux team and contributors
+ org.opencontainers.image.url=https://voidlinux.org
+ org.opencontainers.image.documentation=https://github.com/${{ github.repository }}
+ org.opencontainers.image.source=https://github.com/${{ github.repository }}
+ org.opencontainers.image.vendor=Void Linux
+ org.opencontainers.image.title=Void Linux build root
+ org.opencontainers.image.description=Image for building packages with xbps-src on Void Linux
+
+ - name: Set up QEMU
+ uses: docker/setup-qemu-action@v2
+
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v2
+
+ - name: Login to GCHR
+ if: github.event_name != 'pull_request'
+ uses: docker/login-action@v2
+ with:
+ registry: ghcr.io
+ username: ${{ github.actor }}
+ password: ${{ secrets.GITHUB_TOKEN }}
+
+ - name: Build and push images
+ id: build_and_push
+ uses: docker/bake-action@v3
+ with:
+ push: ${{ github.event_name != 'pull_request' }}
+ targets: void-buildroot-${{ matrix.libc }}
+ files: |
+ common/container/docker-bake.hcl
+ ${{ steps.meta.outputs.bake-file }}
+ set: |
+ _common.cache-to=type=gha
+ _common.cache-from=type=gha
diff --git a/common/container/Containerfile b/common/container/Containerfile
new file mode 100644
index 0000000000000..6b5478cb6a3af
--- /dev/null
+++ b/common/container/Containerfile
@@ -0,0 +1,35 @@
+# syntax=docker/dockerfile:1
+FROM --platform=${BUILDPLATFORM} alpine:3.18 AS bootstrap
+ARG TARGETPLATFORM
+ARG MIRROR=https://repo-ci.voidlinux.org
+ARG LIBC
+RUN apk add ca-certificates curl && \
+ curl "${MIRROR}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz" | tar vJx
+COPY common/repo-keys/* /target/var/db/xbps/keys/
+COPY common/container/setup.sh /bootstrap/setup.sh
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -S \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target
+
+FROM --platform=${BUILDPLATFORM} bootstrap AS install
+ARG TARGETPLATFORM
+ARG MIRROR
+ARG LIBC
+COPY --from=bootstrap /target /target
+COPY common/container/noextract.conf /target/etc/xbps.d/noextract.conf
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -y \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target \
+ base-chroot void-repo-bootstrap
+
+FROM scratch AS image
+COPY --link --from=install /target /
+RUN \
+ install -dm1777 tmp; \
+ xbps-reconfigure -fa; \
+ rm -rf /var/cache/xbps/*
+CMD ["/bin/sh"]
diff --git a/common/container/docker-bake.hcl b/common/container/docker-bake.hcl
new file mode 100644
index 0000000000000..f290206f89e6a
--- /dev/null
+++ b/common/container/docker-bake.hcl
@@ -0,0 +1,29 @@
+variable "MIRROR" {
+ default = "https://repo-ci.voidlinux.org/"
+}
+
+target "docker-metadata-action" {}
+
+target "_common" {
+ inherits = ["docker-metadata-action"]
+ dockerfile = "common/container/Containerfile"
+ no-cache-filter = ["bootstrap"]
+ cache-to = ["type=local,dest=/tmp/buildx-cache"]
+ cache-from = ["type=local,src=/tmp/buildx-cache"]
+ target = "image"
+ args = {
+ "MIRROR" = "${MIRROR}"
+ }
+}
+
+target "void-buildroot-glibc" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/386", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "glibc" }
+}
+
+target "void-buildroot-musl" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "musl" }
+}
--git a/common/container/noextract.conf b/common/container/noextract.conf
new file mode 100644
index 0000000000000..be8ac91510c5e
--- /dev/null
+++ b/common/container/noextract.conf
@@ -0,0 +1,13 @@
+noextract=/etc/sv*
+noextract=/usr/share/man*
+noextract=/usr/lib/dracut*
+noextract=/etc/skel*
+noextract=/usr/lib/modprobe.d*
+noextract=/usr/lib/sysctl.d*
+noextract=/usr/lib/udev*
+noextract=/usr/share/bash-completion*
+noextract=/usr/share/fish/vendor-completions.d*
+noextract=/usr/share/zsh/site-functions*
+noextract=/usr/share/info*
+noextract=/usr/share/locale*
+noextract=/usr/lib/gconv*
diff --git a/common/container/setup.sh b/common/container/setup.sh
new file mode 100644
index 0000000000000..f28a2b2073c64
--- /dev/null
+++ b/common/container/setup.sh
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+: "${MIRROR:=https://repo-default.voidlinux.org/}"
+
+suffix() {
+ case "${LIBC:?}" in
+ musl) echo "-musl" ;;
+ esac
+}
+
+repo() {
+ case "${ARCH:?}" in
+ aarch64*) echo "${MIRROR}/current/aarch64" ;;
+ *-musl) echo "${MIRROR}/current/musl" ;;
+ *) echo "${MIRROR}/current" ;;
+ esac
+}
+
+case "${TARGETPLATFORM:?}" in
+linux/arm/v6) ARCH="armv6l$(suffix)" ;;
+linux/arm/v7) ARCH="armv7l$(suffix)" ;;
+linux/arm64) ARCH="aarch64$(suffix)" ;;
+linux/amd64) ARCH="x86_64$(suffix)" ;;
+linux/386) ARCH="i686$(suffix)" ;;
+esac
+
+REPO="$(repo)"
+
+export ARCH REPO
From e5415b923c4ad1b2abdaeb92bc4b587deb084153 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 12 Aug 2023 16:53:14 -0400
Subject: [PATCH 2/2] .github/workflows/{build,cycles}: use new buildroot
images
---
.github/workflows/build.yaml | 19 ++++++++++---------
.github/workflows/cycles.yml | 2 +-
2 files changed, 11 insertions(+), 10 deletions(-)
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index 6577124146575..71e6f12b904f2 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -40,11 +40,12 @@ jobs:
if: "!contains(github.event.pull_request.title, '[ci skip]') && !contains(github.event.pull_request.body, '[ci skip]')"
container:
- image: 'ghcr.io/void-linux/xbps-src-masterdir:20230708RC01-${{ matrix.config.bootstrap }}'
+ image: ghcr.io/void-linux/void-buildroot-${{ matrix.config.libc }}:20230812
+ options: --platform ${{ matrix.config.platform }}
env:
PATH: '/usr/libexec/chroot-git:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin:/usr/local/bin:/tmp/bin'
ARCH: '${{ matrix.config.arch }}'
- BOOTSTRAP: '${{ matrix.config.bootstrap }}'
+ BOOTSTRAP: '${{ matrix.config.host }}'
TEST: '${{ matrix.config.test }}'
HOSTREPO: /hostrepo
@@ -52,13 +53,13 @@ jobs:
fail-fast: false
matrix:
config:
- - { arch: x86_64, bootstrap: x86_64, test: 1 }
- - { arch: i686, bootstrap: i686, test: 1 }
- - { arch: aarch64, bootstrap: x86_64, test: 0 }
- - { arch: armv7l, bootstrap: x86_64, test: 0 }
- - { arch: x86_64-musl, bootstrap: x86_64-musl, test: 1 }
- - { arch: armv6l-musl, bootstrap: x86_64-musl, test: 0 }
- - { arch: aarch64-musl, bootstrap: x86_64-musl, test: 0 }
+ - { arch: x86_64, host: x86_64, libc: glibc, platform: linux/amd64, test: 1 }
+ - { arch: i686, host: i686, libc: glibc, platform: linux/386, test: 1 }
+ - { arch: aarch64, host: x86_64, libc: glibc, platform: linux/amd64, test: 0 }
+ - { arch: armv7l, host: x86_64, libc: glibc, platform: linux/amd64, test: 0 }
+ - { arch: x86_64-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 1 }
+ - { arch: armv6l-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 0 }
+ - { arch: aarch64-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 0 }
steps:
- name: Prepare container
diff --git a/.github/workflows/cycles.yml b/.github/workflows/cycles.yml
index 394a4ffe51a03..0dc0a17f3efab 100644
--- a/.github/workflows/cycles.yml
+++ b/.github/workflows/cycles.yml
@@ -10,7 +10,7 @@ jobs:
permissions:
issues: write
container:
- image: 'ghcr.io/void-linux/xbps-src-masterdir:20230708RC01-x86_64-musl'
+ image: 'ghcr.io/void-linux/void-buildroot-musl:20230812'
env:
PATH: '/usr/libexec/chroot-git:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin:/usr/local/bin:/tmp/bin'
steps:
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PR PATCH] [Updated] common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
` (3 preceding siblings ...)
2023-08-12 21:07 ` [PR PATCH] [Updated] " classabbyamp
@ 2023-08-18 19:59 ` classabbyamp
2023-08-18 20:55 ` classabbyamp
2023-08-18 20:55 ` [PR PATCH] [Closed]: " classabbyamp
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-18 19:59 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 955 bytes --]
There is an updated pull request by classabbyamp against master on the void-packages repository
https://github.com/classabbyamp/void-packages build-root-image
https://github.com/void-linux/void-packages/pull/45320
common/container: move masterdir image building to void-packages
see void-linux/void-docker#11
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
- example CI run with the new image: https://github.com/classabbyamp/void-packages/actions/runs/5843401357
before:
```
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64 607MB
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64-musl 522MB
```
after:
```
localhost:5000/void-buildroot-glibc latest 438MB
localhost:5000/void-buildroot-musl latest 383MB
```
A patch file from https://github.com/void-linux/void-packages/pull/45320.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-root-image-45320.patch --]
[-- Type: text/x-diff, Size: 11492 bytes --]
From 0460d7388e384d68ae28c6b3a31edd6d383325cf Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sun, 30 Jul 2023 01:00:16 -0400
Subject: [PATCH 1/2] common/container: move masterdir image building to
void-packages
see void-linux/void-docker#11
---
.dockerignore | 3 +
.github/workflows/container.yaml | 98 ++++++++++++++++++++++++++++++++
common/container/Containerfile | 35 ++++++++++++
common/container/docker-bake.hcl | 29 ++++++++++
| 13 +++++
common/container/setup.sh | 29 ++++++++++
6 files changed, 207 insertions(+)
create mode 100644 .dockerignore
create mode 100644 .github/workflows/container.yaml
create mode 100644 common/container/Containerfile
create mode 100644 common/container/docker-bake.hcl
create mode 100644 common/container/noextract.conf
create mode 100644 common/container/setup.sh
diff --git a/.dockerignore b/.dockerignore
new file mode 100644
index 0000000000000..2d28584d8dbfb
--- /dev/null
+++ b/.dockerignore
@@ -0,0 +1,3 @@
+*
+!common/container/
+!common/repo-keys/
diff --git a/.github/workflows/container.yaml b/.github/workflows/container.yaml
new file mode 100644
index 0000000000000..957b6e849d591
--- /dev/null
+++ b/.github/workflows/container.yaml
@@ -0,0 +1,98 @@
+---
+name: 'Build buildroot containers'
+
+on:
+ workflow_dispatch:
+ pull_request:
+ branches:
+ - master
+ paths:
+ - common/container/**
+ push:
+ branches:
+ - master
+ paths:
+ - common/container/**
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+
+ permissions:
+ contents: read
+ packages: write
+
+ strategy:
+ matrix:
+ libc:
+ - glibc
+ - musl
+
+ steps:
+ - name: Checkout
+ uses: classabbyamp/treeless-checkout-action@v1
+
+ - name: Get image release
+ id: release
+ run: |
+ # gets the list of all date-shaped tags for the image, finds the most recent one
+ tag="$(skopeo list-tags "docker://ghcr.io/${{ github.repository_owner }}/void-buildroot-${{ matrix.libc }}" | \
+ jq -r '.Tags | sort | reverse | map(select(test("^[0-9]{8}(R[0-9]+)?$")))[0]')"
+ # tags from a different day or pre-YYYYMMDDRN
+ if [ "${tag%R*}" != "$(date -u +%Y%m%d)" ] || [ "${tag%R*}" = "${tag}" ]; then
+ rel=1
+ else
+ rel=$(( ${tag##*R} + 1 ))
+ fi
+ echo "rel=${rel}" >> "${GITHUB_OUTPUT}"
+
+ - name: Docker metadata
+ id: meta
+ uses: docker/metadata-action@v4
+ with:
+ images: |
+ ghcr.io/${{ github.repository_owner }}/void-buildroot-${{ matrix.libc }}
+ tags: |
+ type=sha,prefix=
+ type=raw,value=latest,enable={{is_default_branch}}
+ type=raw,value={{date 'YYYYMMDD'}}R${{ steps.release.outputs.rel }},enable={{is_default_branch}},priority=1000
+ flavor: latest=false
+ labels: |
+ org.opencontainers.image.authors=Void Linux team and contributors
+ org.opencontainers.image.url=https://voidlinux.org
+ org.opencontainers.image.documentation=https://github.com/${{ github.repository }}
+ org.opencontainers.image.source=https://github.com/${{ github.repository }}
+ org.opencontainers.image.vendor=Void Linux
+ org.opencontainers.image.title=Void Linux build root
+ org.opencontainers.image.description=Image for building packages with xbps-src on Void Linux
+
+ - name: Set up QEMU
+ uses: docker/setup-qemu-action@v2
+
+ - name: Set up Docker Buildx
+ uses: docker/setup-buildx-action@v2
+
+ - name: Login to GCHR
+ if: github.event_name != 'pull_request'
+ uses: docker/login-action@v2
+ with:
+ registry: ghcr.io
+ username: ${{ github.actor }}
+ password: ${{ secrets.GITHUB_TOKEN }}
+
+ - name: Build and push images
+ id: build_and_push
+ uses: docker/bake-action@v3
+ with:
+ push: ${{ github.event_name != 'pull_request' }}
+ targets: void-buildroot-${{ matrix.libc }}
+ files: |
+ common/container/docker-bake.hcl
+ ${{ steps.meta.outputs.bake-file }}
+ set: |
+ _common.cache-to=type=gha
+ _common.cache-from=type=gha
diff --git a/common/container/Containerfile b/common/container/Containerfile
new file mode 100644
index 0000000000000..6b5478cb6a3af
--- /dev/null
+++ b/common/container/Containerfile
@@ -0,0 +1,35 @@
+# syntax=docker/dockerfile:1
+FROM --platform=${BUILDPLATFORM} alpine:3.18 AS bootstrap
+ARG TARGETPLATFORM
+ARG MIRROR=https://repo-ci.voidlinux.org
+ARG LIBC
+RUN apk add ca-certificates curl && \
+ curl "${MIRROR}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz" | tar vJx
+COPY common/repo-keys/* /target/var/db/xbps/keys/
+COPY common/container/setup.sh /bootstrap/setup.sh
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -S \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target
+
+FROM --platform=${BUILDPLATFORM} bootstrap AS install
+ARG TARGETPLATFORM
+ARG MIRROR
+ARG LIBC
+COPY --from=bootstrap /target /target
+COPY common/container/noextract.conf /target/etc/xbps.d/noextract.conf
+RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
+ . /bootstrap/setup.sh; \
+ XBPS_TARGET_ARCH=${ARCH} xbps-install -y \
+ -R "${REPO}" -R "${REPO}/bootstrap" \
+ -r /target \
+ base-chroot void-repo-bootstrap
+
+FROM scratch AS image
+COPY --link --from=install /target /
+RUN \
+ install -dm1777 tmp; \
+ xbps-reconfigure -fa; \
+ rm -rf /var/cache/xbps/*
+CMD ["/bin/sh"]
diff --git a/common/container/docker-bake.hcl b/common/container/docker-bake.hcl
new file mode 100644
index 0000000000000..f290206f89e6a
--- /dev/null
+++ b/common/container/docker-bake.hcl
@@ -0,0 +1,29 @@
+variable "MIRROR" {
+ default = "https://repo-ci.voidlinux.org/"
+}
+
+target "docker-metadata-action" {}
+
+target "_common" {
+ inherits = ["docker-metadata-action"]
+ dockerfile = "common/container/Containerfile"
+ no-cache-filter = ["bootstrap"]
+ cache-to = ["type=local,dest=/tmp/buildx-cache"]
+ cache-from = ["type=local,src=/tmp/buildx-cache"]
+ target = "image"
+ args = {
+ "MIRROR" = "${MIRROR}"
+ }
+}
+
+target "void-buildroot-glibc" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/386", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "glibc" }
+}
+
+target "void-buildroot-musl" {
+ inherits = ["_common"]
+ platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
+ args = { "LIBC" = "musl" }
+}
--git a/common/container/noextract.conf b/common/container/noextract.conf
new file mode 100644
index 0000000000000..be8ac91510c5e
--- /dev/null
+++ b/common/container/noextract.conf
@@ -0,0 +1,13 @@
+noextract=/etc/sv*
+noextract=/usr/share/man*
+noextract=/usr/lib/dracut*
+noextract=/etc/skel*
+noextract=/usr/lib/modprobe.d*
+noextract=/usr/lib/sysctl.d*
+noextract=/usr/lib/udev*
+noextract=/usr/share/bash-completion*
+noextract=/usr/share/fish/vendor-completions.d*
+noextract=/usr/share/zsh/site-functions*
+noextract=/usr/share/info*
+noextract=/usr/share/locale*
+noextract=/usr/lib/gconv*
diff --git a/common/container/setup.sh b/common/container/setup.sh
new file mode 100644
index 0000000000000..f28a2b2073c64
--- /dev/null
+++ b/common/container/setup.sh
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+: "${MIRROR:=https://repo-default.voidlinux.org/}"
+
+suffix() {
+ case "${LIBC:?}" in
+ musl) echo "-musl" ;;
+ esac
+}
+
+repo() {
+ case "${ARCH:?}" in
+ aarch64*) echo "${MIRROR}/current/aarch64" ;;
+ *-musl) echo "${MIRROR}/current/musl" ;;
+ *) echo "${MIRROR}/current" ;;
+ esac
+}
+
+case "${TARGETPLATFORM:?}" in
+linux/arm/v6) ARCH="armv6l$(suffix)" ;;
+linux/arm/v7) ARCH="armv7l$(suffix)" ;;
+linux/arm64) ARCH="aarch64$(suffix)" ;;
+linux/amd64) ARCH="x86_64$(suffix)" ;;
+linux/386) ARCH="i686$(suffix)" ;;
+esac
+
+REPO="$(repo)"
+
+export ARCH REPO
From d742a2f77454879364e3beca6a70355b8f6a1356 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Sat, 12 Aug 2023 16:53:14 -0400
Subject: [PATCH 2/2] .github/workflows/{build,cycles}: use new buildroot
images
---
.github/workflows/build.yaml | 19 ++++++++++---------
.github/workflows/cycles.yml | 2 +-
2 files changed, 11 insertions(+), 10 deletions(-)
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index 6577124146575..9b84be9ba1321 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -40,11 +40,12 @@ jobs:
if: "!contains(github.event.pull_request.title, '[ci skip]') && !contains(github.event.pull_request.body, '[ci skip]')"
container:
- image: 'ghcr.io/void-linux/xbps-src-masterdir:20230708RC01-${{ matrix.config.bootstrap }}'
+ image: ghcr.io/void-linux/void-buildroot-${{ matrix.config.libc }}:20230818R1
+ options: --platform ${{ matrix.config.platform }}
env:
PATH: '/usr/libexec/chroot-git:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin:/usr/local/bin:/tmp/bin'
ARCH: '${{ matrix.config.arch }}'
- BOOTSTRAP: '${{ matrix.config.bootstrap }}'
+ BOOTSTRAP: '${{ matrix.config.host }}'
TEST: '${{ matrix.config.test }}'
HOSTREPO: /hostrepo
@@ -52,13 +53,13 @@ jobs:
fail-fast: false
matrix:
config:
- - { arch: x86_64, bootstrap: x86_64, test: 1 }
- - { arch: i686, bootstrap: i686, test: 1 }
- - { arch: aarch64, bootstrap: x86_64, test: 0 }
- - { arch: armv7l, bootstrap: x86_64, test: 0 }
- - { arch: x86_64-musl, bootstrap: x86_64-musl, test: 1 }
- - { arch: armv6l-musl, bootstrap: x86_64-musl, test: 0 }
- - { arch: aarch64-musl, bootstrap: x86_64-musl, test: 0 }
+ - { arch: x86_64, host: x86_64, libc: glibc, platform: linux/amd64, test: 1 }
+ - { arch: i686, host: i686, libc: glibc, platform: linux/386, test: 1 }
+ - { arch: aarch64, host: x86_64, libc: glibc, platform: linux/amd64, test: 0 }
+ - { arch: armv7l, host: x86_64, libc: glibc, platform: linux/amd64, test: 0 }
+ - { arch: x86_64-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 1 }
+ - { arch: armv6l-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 0 }
+ - { arch: aarch64-musl, host: x86_64-musl, libc: musl, platform: linux/amd64, test: 0 }
steps:
- name: Prepare container
diff --git a/.github/workflows/cycles.yml b/.github/workflows/cycles.yml
index 394a4ffe51a03..935daadec5701 100644
--- a/.github/workflows/cycles.yml
+++ b/.github/workflows/cycles.yml
@@ -10,7 +10,7 @@ jobs:
permissions:
issues: write
container:
- image: 'ghcr.io/void-linux/xbps-src-masterdir:20230708RC01-x86_64-musl'
+ image: 'ghcr.io/void-linux/void-buildroot-musl:20230818R1'
env:
PATH: '/usr/libexec/chroot-git:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/sbin:/usr/local/bin:/tmp/bin'
steps:
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
` (4 preceding siblings ...)
2023-08-18 19:59 ` classabbyamp
@ 2023-08-18 20:55 ` classabbyamp
2023-08-18 20:55 ` [PR PATCH] [Closed]: " classabbyamp
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-18 20:55 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 229 bytes --]
New comment by classabbyamp on void-packages repository
https://github.com/void-linux/void-packages/pull/45320#issuecomment-1684427535
Comment:
76c6e77f3514865439092d6ee0133fedb3e51ce0
c828e16253cce52c0028d19bd1834ce0a8de04bc
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PR PATCH] [Closed]: common/container: move masterdir image building to void-packages
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
` (5 preceding siblings ...)
2023-08-18 20:55 ` classabbyamp
@ 2023-08-18 20:55 ` classabbyamp
6 siblings, 0 replies; 8+ messages in thread
From: classabbyamp @ 2023-08-18 20:55 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 780 bytes --]
There's a closed pull request on the void-packages repository
common/container: move masterdir image building to void-packages
https://github.com/void-linux/void-packages/pull/45320
Description:
see void-linux/void-docker#11
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **YES**
- example CI run with the new image: https://github.com/classabbyamp/void-packages/actions/runs/5843401357
before:
```
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64 607MB
ghcr.io/void-linux/xbps-src-masterdir latest-x86_64-musl 522MB
```
after:
```
localhost:5000/void-buildroot-glibc latest 438MB
localhost:5000/void-buildroot-musl latest 383MB
```
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2023-08-18 20:55 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-30 5:31 [PR PATCH] common/container: move masterdir image building to void-packages classabbyamp
2023-08-12 19:49 ` [PR PATCH] [Updated] " classabbyamp
2023-08-12 21:06 ` classabbyamp
2023-08-12 21:06 ` classabbyamp
2023-08-12 21:07 ` [PR PATCH] [Updated] " classabbyamp
2023-08-18 19:59 ` classabbyamp
2023-08-18 20:55 ` classabbyamp
2023-08-18 20:55 ` [PR PATCH] [Closed]: " classabbyamp
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).