Skip to content

deblobbify, replacing the system folder with several other components #362

deblobbify, replacing the system folder with several other components

deblobbify, replacing the system folder with several other components #362

Workflow file for this run

name: Build and push Docker image
on:
push:
branches:
- master
pull_request:
schedule:
- cron: '0 2 * * 0'
workflow_dispatch:
env:
CI: true
DOCKER_BUILDKIT: 1
# The GitHub ARM runner is capable of running
# $PREFIX/bin/apt-get upgrade from within the Dockerfile
# natively during the update process for both aarch64
# and arm, demonstrating that it is compatible with
# 32-bit binaries and capable of completely
# replacing QEMU, but using it in the same workflow
# as the x86 runner appears to require two separate jobs.
jobs:
ARM:
runs-on: ubuntu-24.04-arm
strategy:
matrix:
ARCHITECTURE:
- aarch64
- arm
steps:
- name: Clone repository
uses: actions/checkout@v4
- name: Set architecture variable
run: echo "ARCHITECTURE=${{ matrix.ARCHITECTURE }}" >> $GITHUB_ENV
- name: Build image
run: ./generate.sh
- name: Login to Docker Hub
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' && github.repository == 'termux/termux-docker'
uses: docker/login-action@v3
with:
username: grimler
password: ${{ secrets.GRIMLER_DOCKER_TOKEN }}
- name: Push to Docker Hub
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' && github.repository == 'termux/termux-docker'
run: docker push termux/termux-docker:${{ env.ARCHITECTURE }}
- name: Export container as tar archive
if: always()
run: |
docker run \
--name termux-docker-${{ env.ARCHITECTURE }} \
termux/termux-docker:${{ env.ARCHITECTURE }} \
uname -a
docker stop termux-docker-${{ env.ARCHITECTURE }}
docker export -o termux-docker-${{ env.ARCHITECTURE }}.tar \
termux-docker-${{ env.ARCHITECTURE }}
sha256sum termux-docker-${{ env.ARCHITECTURE }}.tar
- name: Store tar archive
if: always()
uses: actions/upload-artifact@v4
with:
name: termux-docker-${{ env.ARCHITECTURE }}-${{ github.sha }}
path: termux-docker-${{ env.ARCHITECTURE }}.tar
x86:
runs-on: ubuntu-latest
strategy:
matrix:
ARCHITECTURE:
- x86_64
- i686
steps:
- name: Clone repository
uses: actions/checkout@v4
- name: Set architecture variable
run: echo "ARCHITECTURE=${{ matrix.ARCHITECTURE }}" >> $GITHUB_ENV
- name: Build image
run: ./generate.sh
- name: Login to Docker Hub
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' && github.repository == 'termux/termux-docker'
uses: docker/login-action@v3
with:
username: grimler
password: ${{ secrets.GRIMLER_DOCKER_TOKEN }}
- name: Push to Docker Hub
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' && github.repository == 'termux/termux-docker'
run: |
docker push termux/termux-docker:${{ env.ARCHITECTURE }}
if [ ${{ env.ARCHITECTURE }} = i686 ]; then
docker push termux/termux-docker:latest
fi
- name: Export container as tar archive
if: always()
run: |
docker run \
--name termux-docker-${{ env.ARCHITECTURE }} \
termux/termux-docker:${{ env.ARCHITECTURE }} \
uname -a
docker stop termux-docker-${{ env.ARCHITECTURE }}
docker export -o termux-docker-${{ env.ARCHITECTURE }}.tar \
termux-docker-${{ env.ARCHITECTURE }}
sha256sum termux-docker-${{ env.ARCHITECTURE }}.tar
- name: Store tar archive
if: always()
uses: actions/upload-artifact@v4
with:
name: termux-docker-${{ env.ARCHITECTURE }}-${{ github.sha }}
path: termux-docker-${{ env.ARCHITECTURE }}.tar