Files
swingmusic-extended/.github/workflows/aarch64.yml
T
jensgrunzer1 95ae58a868 s
2024-11-20 00:27:10 +01:00

52 lines
2.1 KiB
YAML

name: New Release
run-name: Release v${{ github.event.inputs.tag }}
on:
workflow_dispatch:
jobs:
build:
runs-on: [ubuntu-latest]
name: Building aarch64 binary
steps:
- name: Installing Packages
run: |
sudo apt update -y
sudo apt -y install binfmt-support qemu-user-static systemd-container wget libarchive-tools
- name: Starting Services
run: |
sudo systemctl restart systemd-binfmt
- name: Downloading Arch Linux Arm Image for rpi4 aarch64
run: |
wget http://os.archlinuxarm.org/os/ArchLinuxARM-rpi-aarch64-latest.tar.gz
- name: Extracting Image
run: |
mkdir root
sudo tar xpf ArchLinuxARM-rpi-aarch64-latest.tar.gz -C root --warning=no-unknown-keyword
sudo chmod 770 root
sync
- name: Building Swingmusic in qemu
run: |
wget https://raw.githubusercontent.com/jensgrunzer1/swingmusic/refs/heads/master/aarch64_buildscript
chmod +x aarch64_buildscript
cp aarch64_buildscript root/
sudo systemd-nspawn -q --bind /usr/bin/qemu-aarch64-static -b -D root ./aarch64_buildscript
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
with:
tag_name: ${{ github.run_number }}
release_name: Release ${{ github.run_number }}
draft: false
prerelease: false
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./root/root/swingmusicbuilder/swingmusic/dist/swingmusic
asset_name: swingmusic
asset_content_type: application/octet-stream