π¬ Builds GH-Runner Images (Self-Hosted) DockerHub π¬ #113
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: π¬ Builds GH-Runner Images (Self-Hosted) DockerHub π¬ | |
#REF: https://docs.docker.com/build/ci/github-actions/multi-platform/ | |
#SECRETS: DOCKERHUB_USERNAME || DOCKERHUB_TOKEN | |
#URL: https://hub.docker.com/r/azathothas/gh-runner-aarch64-Linux/tags | |
#For: https://github.com/Azathothas/Toolpacks/settings/actions/runners | |
#------------------------------------------------------------------------------------# | |
on: | |
#push: | |
workflow_dispatch: | |
schedule: | |
- cron: "30 08 * * 4" # 08:30 PM UTC Fri (02:15 AM NPT Fri Midnight) | |
# - cron: "*/30 * * * *" # Every 30 Mins | |
defaults: | |
run: | |
shell: bash | |
working-directory: /tmp | |
#------------------------------------------------------------------------------------# | |
jobs: | |
build-push-docker-alpine: | |
name: Push (Alpine) --> Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/alpine-builder.dockerfile" "/tmp/DOCKERFILES/alpine-builder.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/alpine-builder | |
- name: Docker Build and Push (alpine-builder) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/alpine-builder.dockerfile" | |
platforms: "linux/amd64,linux/arm64" | |
tags: | | |
azathothas/alpine-builder:latest | |
azathothas/alpine-builder:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-alpine-ndk: | |
name: Push (Alpine-NDK) --> Docker Hub | |
#needs: [build-push-docker-alpine] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/alpine-builder-ndk.dockerfile" "/tmp/DOCKERFILES/alpine-builder-ndk.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/alpine-builder-ndk | |
- name: Docker Build and Push (alpine-builder) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/alpine-builder-ndk.dockerfile" | |
#platforms: "linux/amd64,linux/arm64" | |
platforms: "linux/amd64" | |
tags: | | |
azathothas/alpine-builder-ndk:latest | |
azathothas/alpine-builder-ndk:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-archlinux-builder: | |
name: Push (ArchLinux-Builder) --> Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/archlinux-builder.dockerfile" "/tmp/DOCKERFILES/archlinux-builder.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/archlinux-builder | |
- name: Docker Build and Push (ArchLinux-Builder) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/archlinux-builder.dockerfile" | |
platforms: "linux/amd64,linux/arm64" | |
tags: | | |
azathothas/archlinux-builder:latest | |
azathothas/archlinux-builder:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-ubuntu-base-aarch64: | |
name: Push (Ubuntu-Base-aarch64) --> Docker Hub | |
runs-on: arm64-linux-healthchecker | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/ubuntu-systemd-base.dockerfile" "/tmp/DOCKERFILES/ubuntu-systemd-base.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/ubuntu-systemd-base | |
- name: Docker Build and Push (Ubuntu-Systemd-Base) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/ubuntu-systemd-base.dockerfile" | |
platforms: "linux/arm64" | |
tags: | | |
azathothas/ubuntu-systemd-base:latest | |
azathothas/ubuntu-systemd-base:aarch64 | |
azathothas/ubuntu-systemd-base:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-ubuntu-base-x64: | |
name: Push (Ubuntu-Base-x64) --> Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/ubuntu-systemd-base.dockerfile" "/tmp/DOCKERFILES/ubuntu-systemd-base.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/ubuntu-systemd-base | |
- name: Docker Build and Push (Ubuntu-Systemd-Base) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/ubuntu-systemd-base.dockerfile" | |
platforms: "linux/amd64" | |
tags: | | |
azathothas/ubuntu-systemd-base:latest | |
azathothas/ubuntu-systemd-base:x86_64 | |
azathothas/ubuntu-systemd-base:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-debian-unstable-base: | |
name: Push (Debian-Builder) --> Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/debian-builder-unstable.dockerfile" "/tmp/DOCKERFILES/debian-builder-unstable.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/debian-builder-unstable | |
- name: Docker Build and Push (Debian-Unstable-Base) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/debian-builder-unstable.dockerfile" | |
platforms: "linux/amd64,linux/arm64" | |
tags: | | |
azathothas/debian-builder-unstable:latest | |
azathothas/debian-builder-unstable:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-ubuntu-builder: | |
name: Push (Ubuntu-Builder) --> Docker Hub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/ubuntu-builder.dockerfile" "/tmp/DOCKERFILES/ubuntu-builder.dockerfile" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/ubuntu-builder | |
- name: Docker Build and Push (ubuntu-builder) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/ubuntu-builder.dockerfile" | |
platforms: "linux/amd64,linux/arm64" | |
tags: | | |
azathothas/ubuntu-builder:latest | |
azathothas/ubuntu-builder:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-runner-aarch64: | |
name: Push (runner-aarch64) --> Docker Hub | |
runs-on: ubuntu-latest | |
#needs: [build-push-docker-ubuntu-base] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/aarch64-ubuntu.dockerfile" "/tmp/DOCKERFILES/aarch64-ubuntu.dockerfile" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/manager.sh" "/tmp/DOCKERFILES/manager.sh" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/gh-runner-aarch64-ubuntu | |
- name: Docker Build and Push (gh-runner-aarch64-ubuntu) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/aarch64-ubuntu.dockerfile" | |
#platforms: "linux/amd64,linux/arm64" | |
platforms: "linux/arm64" | |
tags: | | |
azathothas/gh-runner-aarch64-ubuntu:latest | |
azathothas/gh-runner-aarch64-ubuntu:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# | |
build-push-docker-runner-x86-64: | |
name: Push (runner-x86_64) --> Docker Hub | |
runs-on: ubuntu-latest | |
#needs: [build-push-docker-ubuntu-base] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
path: main | |
filter: "blob:none" | |
- name: Debloat Runner | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
bash <(curl -qfsSL "https://pub.ajam.dev/repos/Azathothas/Arsenal/misc/Github/Runners/Ubuntu/debloat.sh") | |
continue-on-error: true | |
- name: Setup Env | |
run: | | |
#Presets | |
set +x ; set +e | |
#--------------# | |
#Docker Tags | |
DOCKER_TAG="v$(date +'%Y.%m.%d')" && export DOCKER_TAG="$DOCKER_TAG" | |
echo "DOCKER_TAG=$DOCKER_TAG" >> "$GITHUB_ENV" | |
#Copy dockerfiles | |
mkdir -p "/tmp/DOCKERFILES" && cd "/tmp/DOCKERFILES" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/x86_64-ubuntu.dockerfile" "/tmp/DOCKERFILES/x86_64-ubuntu.dockerfile" | |
cp "$GITHUB_WORKSPACE/main/.github/runners/manager.sh" "/tmp/DOCKERFILES/manager.sh" | |
continue-on-error: true | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
continue-on-error: true | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
continue-on-error: true | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: "${{ secrets.DOCKERHUB_USERNAME }}" | |
password: "${{ secrets.DOCKERHUB_TOKEN }}" | |
continue-on-error: true | |
#https://hub.docker.com/r/azathothas/gh-runner-x86_64-ubuntu | |
- name: Docker Build and Push (gh-runner-x86_64-ubuntu) | |
uses: docker/build-push-action@v6 | |
with: | |
context: /tmp/DOCKERFILES/ | |
file: "/tmp/DOCKERFILES/x86_64-ubuntu.dockerfile" | |
#platforms: "linux/amd64,linux/arm64" | |
platforms: "linux/amd64" | |
tags: | | |
azathothas/gh-runner-x86_64-ubuntu:latest | |
azathothas/gh-runner-x86_64-ubuntu:${{ env.DOCKER_TAG }} | |
push: true | |
continue-on-error: true | |
#------------------------------------------------------------------------------------# |