Skip to content

Commit e13f5ec

Browse files
selfisekaithe-maldridge
authored andcommitted
support for all void-supported architectures
Closes: #4 [via git-merge-pr]
1 parent ba2849e commit e13f5ec

10 files changed

Lines changed: 81 additions & 31 deletions

.github/workflows/bootstrap.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,19 @@ on:
1010
jobs:
1111
main:
1212
runs-on: ubuntu-latest
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
arch:
17+
- { xbps: x86_64, docker: linux/amd64, libc: glibc }
18+
- { xbps: x86_64-musl, docker: linux/amd64, libc: musl }
19+
- { xbps: i686, docker: linux/386, libc: glibc }
20+
- { xbps: armv6l, docker: linux/arm/v6, libc: glibc }
21+
- { xbps: armv6l-musl, docker: linux/arm/v6, libc: musl }
22+
- { xbps: armv7l, docker: linux/arm, libc: glibc }
23+
- { xbps: armv7l-musl, docker: linux/arm, libc: musl }
24+
- { xbps: aarch64, docker: linux/arm64, libc: glibc }
25+
- { xbps: aarch64-musl, docker: linux/arm64, libc: musl }
1326
steps:
1427
- name: Checkout repo
1528
uses: actions/checkout@master
@@ -31,6 +44,11 @@ jobs:
3144
with:
3245
file: Dockerfile.bootstrap
3346
push: true
47+
platforms: ${{ matrix.arch.docker }}
48+
build-args: |
49+
ARCH=${{ matrix.arch.xbps }}
3450
tags: |
3551
"ghcr.io/void-linux/docker-bootstrap:${{ env.RELEASE_VERSION }}"
3652
"ghcr.io/void-linux/docker-bootstrap:latest"
53+
"ghcr.io/void-linux/docker-bootstrap:latest-${{ matrix.arch.libc }}"
54+
"ghcr.io/void-linux/docker-bootstrap:latest-${{ matrix.arch.xbps }}"

.github/workflows/containers.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,15 @@ jobs:
2020
- mini
2121
- mini-bb
2222
arch:
23-
- x86_64
24-
- x86_64-musl
23+
- { xbps: x86_64, docker: linux/amd64, libc: glibc }
24+
- { xbps: x86_64-musl, docker: linux/amd64, libc: musl }
25+
- { xbps: i686, docker: linux/386, libc: glibc }
26+
- { xbps: armv6l, docker: linux/arm/v6, libc: glibc }
27+
- { xbps: armv6l-musl, docker: linux/arm/v6, libc: musl }
28+
- { xbps: armv7l, docker: linux/arm, libc: glibc }
29+
- { xbps: armv7l-musl, docker: linux/arm, libc: musl }
30+
- { xbps: aarch64, docker: linux/arm64, libc: glibc }
31+
- { xbps: aarch64-musl, docker: linux/arm64, libc: musl }
2532
steps:
2633
- name: Checkout repo
2734
uses: actions/checkout@master
@@ -41,9 +48,12 @@ jobs:
4148
with:
4249
file: Dockerfile.${{ matrix.flavor }}
4350
build-args: |
44-
ARCH=${{ matrix.arch }}
51+
ARCH=${{ matrix.arch.xbps }}
4552
BOOTSTRAP_VERSION=962218b
4653
push: true
54+
platforms: ${{ matrix.arch.docker }}
4755
tags: |
48-
ghcr.io/void-linux/void-linux:latest-${{ matrix.flavor }}-${{ matrix.arch }}
49-
ghcr.io/void-linux/void-linux:${{ github.event.inputs.version }}-${{ matrix.flavor }}-${{ matrix.arch }}
56+
ghcr.io/void-linux/void-linux:latest-${{ matrix.flavor }}-${{ matrix.arch.xbps }}
57+
ghcr.io/void-linux/void-linux:${{ github.event.inputs.version }}-${{ matrix.flavor }}-${{ matrix.arch.xbps }}
58+
ghcr.io/void-linux/void-linux:${{ matrix.flavor }}-${{ matrix.arch.libc }}
59+
ghcr.io/void-linux/void-linux:${{ github.event.inputs.version }}-${{ matrix.flavor }}-${{ matrix.arch.libc }}

.github/workflows/masterdirs.yml

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,15 @@ jobs:
1414
fail-fast: false
1515
matrix:
1616
arch:
17-
- x86_64
18-
- x86_64-musl
19-
- i686
17+
- { xbps: x86_64, docker: linux/amd64, libc: glibc }
18+
- { xbps: x86_64-musl, docker: linux/amd64, libc: musl }
19+
- { xbps: i686, docker: linux/386, libc: glibc }
20+
- { xbps: armv6l, docker: linux/arm/v6, libc: glibc }
21+
- { xbps: armv6l-musl, docker: linux/arm/v6, libc: musl }
22+
- { xbps: armv7l, docker: linux/arm, libc: glibc }
23+
- { xbps: armv7l-musl, docker: linux/arm, libc: musl }
24+
- { xbps: aarch64, docker: linux/arm64, libc: glibc }
25+
- { xbps: aarch64-musl, docker: linux/arm64, libc: musl }
2026
steps:
2127
- name: Checkout repo
2228
uses: actions/checkout@master
@@ -36,9 +42,12 @@ jobs:
3642
with:
3743
file: Dockerfile.masterdir
3844
build-args: |
39-
ARCH=${{ matrix.arch }}
45+
ARCH=${{ matrix.arch.xbps }}
4046
BOOTSTRAP_VERSION=latest
4147
push: true
48+
platforms: ${{ matrix.arch.docker }}
4249
tags: |
43-
ghcr.io/void-linux/xbps-src-masterdir:latest-${{ matrix.arch }}
44-
ghcr.io/void-linux/xbps-src-masterdir:${{ github.event.inputs.version }}-${{ matrix.arch }}
50+
ghcr.io/void-linux/xbps-src-masterdir:latest-${{ matrix.arch.xbps }}
51+
ghcr.io/void-linux/xbps-src-masterdir:${{ github.event.inputs.version }}-${{ matrix.arch.xbps }}
52+
ghcr.io/void-linux/xbps-src-masterdir:latest-${{ matrix.arch.libc }}
53+
ghcr.io/void-linux/xbps-src-masterdir:${{ github.event.inputs.version }}-${{ matrix.arch.libc }}

Dockerfile.bootstrap

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@ RUN apk add ca-certificates curl && \
77
curl ${REPOSITORY}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz | \
88
tar vJx && \
99
rm -f /etc/ssl/certs/2e5ac55d.* && \
10+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
1011
XBPS_ARCH=${ARCH} xbps-install.static -yMU \
11-
--repository=${REPOSITORY}/current \
12-
--repository=${REPOSITORY}/current/musl \
12+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
13+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1314
-r /target \
1415
base-minimal
1516

Dockerfile.full

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,11 @@ FROM ${BOOTSTRAP_SOURCE}:${BOOTSTRAP_VERSION} as build
44
COPY keys/* /target/var/db/xbps/keys/
55
ARG REPOSITORY=https://repo-us.voidlinux.org
66
ARG ARCH=x86_64
7-
RUN XBPS_ARCH=${ARCH} xbps-install -yMUS \
8-
--repository=${REPOSITORY}/current \
9-
--repository=${REPOSITORY}/current/musl \
7+
RUN \
8+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
9+
XBPS_ARCH=${ARCH} xbps-install -yMUS \
10+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1012
-r /target \
1113
base-minimal
1214

Dockerfile.masterdir

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,11 @@ FROM ${BOOTSTRAP_SOURCE}:${BOOTSTRAP_VERSION} as build
44
COPY keys/* /target/var/db/xbps/keys/
55
ARG REPOSITORY=https://repo-us.voidlinux.org
66
ARG ARCH=x86_64
7-
RUN XBPS_ARCH=${ARCH} xbps-install -yMUS \
8-
--repository=${REPOSITORY}/current \
9-
--repository=${REPOSITORY}/current/musl \
7+
RUN \
8+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
9+
XBPS_ARCH=${ARCH} xbps-install -yMUS \
10+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1012
-r /target \
1113
base-chroot chroot-curl
1214

Dockerfile.mini

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ COPY keys/* /target/var/db/xbps/keys/
55
COPY noextract.conf /target/etc/xbps.d/noextract.conf
66
ARG REPOSITORY=https://repo-us.voidlinux.org
77
ARG ARCH=x86_64
8-
RUN XBPS_ARCH=${ARCH} xbps-install -yMU \
9-
--repository=${REPOSITORY}/current \
10-
--repository=${REPOSITORY}/current/musl \
8+
RUN \
9+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
10+
XBPS_ARCH=${ARCH} xbps-install -yMU \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
12+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1113
-r /target \
1214
xbps base-files dash coreutils grep run-parts sed gawk && \
1315
rm -rf /target/var/cache/

Dockerfile.mini-bb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ COPY keys/* /target/var/db/xbps/keys/
55
COPY noextract.conf /target/etc/xbps.d/noextract.conf
66
ARG REPOSITORY=https://repo-us.voidlinux.org
77
ARG ARCH=x86_64
8-
RUN XBPS_ARCH=${ARCH} xbps-install -yMU \
9-
--repository=${REPOSITORY}/current \
10-
--repository=${REPOSITORY}/current/musl \
8+
RUN \
9+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
10+
XBPS_ARCH=${ARCH} xbps-install -yMU \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
12+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1113
-r /target \
1214
xbps base-files busybox-huge && \
1315
rm -rf /target/var/cache/

Dockerfile.thin

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ COPY keys/* /target/var/db/xbps/keys/
55
COPY noextract.conf /target/etc/xbps.d/noextract.conf
66
ARG REPOSITORY=https://repo-us.voidlinux.org
77
ARG ARCH=x86_64
8-
RUN XBPS_ARCH=${ARCH} xbps-install -yMU \
9-
--repository=${REPOSITORY}/current \
10-
--repository=${REPOSITORY}/current/musl \
8+
RUN \
9+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
10+
XBPS_ARCH=${ARCH} xbps-install -yMU \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
12+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1113
-r /target \
1214
xbps base-files dash coreutils grep run-parts sed gawk && \
1315
rm -rf /target/var/cache/

Dockerfile.thin-bb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ COPY keys/* /target/var/db/xbps/keys/
55
COPY noextract.conf /target/etc/xbps.d/noextract.conf
66
ARG REPOSITORY=https://repo-us.voidlinux.org
77
ARG ARCH=x86_64
8-
RUN XBPS_ARCH=${ARCH} xbps-install -yMU \
9-
--repository=${REPOSITORY}/current \
10-
--repository=${REPOSITORY}/current/musl \
8+
RUN \
9+
if [[ "$ARCH" == "aarch64"* ]]; then export ARCH_DIR_PART='/aarch64'; fi; \
10+
XBPS_ARCH=${ARCH} xbps-install -yMU \
11+
--repository=${REPOSITORY}/current${ARCH_DIR_PART} \
12+
--repository=${REPOSITORY}/current${ARCH_DIR_PART}/musl \
1113
-r /target \
1214
xbps base-files busybox-huge && \
1315
rm -rf /target/var/cache/

0 commit comments

Comments
 (0)