3p automated build scripts #1
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
# This automation builds a aarch64 Ubuntu container | |
name: Build Container | |
on: | |
# Allows you to run this workflow manually from the Actions tag | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
- development | |
paths: | |
- .github/workflows/build-container.yaml | |
jobs: | |
build-container: | |
name: Build Ubuntu container for aarch64 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
# We use ghcr.io to store the docker image cache for ARM builds | |
packages: write | |
steps: | |
- name: Run build command (aarch64) | |
uses: uraimo/run-on-arch-action@v2 | |
with: | |
env: | | |
GITHUB_WORKFLOW: ${{ github.workflow }} | |
SCCACHE_VER: 0.5.4 | |
arch: aarch64 | |
distro: ubuntu_latest | |
githubToken: ${{ github.token }} | |
shell: /bin/bash | |
install: | | |
apt-get update | |
apt-get install -y build-essential cmake curl git libssl-dev libffi-dev libbz2-dev libgdbm-compat-dev libgdbm-dev liblzma-dev libreadline-dev libtool \ | |
ninja-build python3 python3-pip tcl8.6-dev tk8.6-dev texinfo software-properties-common | |
python3 -m pip install boto3 certifi | |
curl -L 'https://github.com/mozilla/sccache/releases/download/v0.5.4/sccache-v0.5.4-aarch64-unknown-linux-musl.tar.gz' \ | |
| tar xzf - -O --wildcards '*/sccache' > '/usr/local/bin/sccache' | |
chmod +x '/usr/local/bin/sccache' | |
run: | | |
lsb_release -a | |
uname -a | |
sccache --version | |
cmake --version | |
git --version | |
python3 --version |