parch-iso-plasma/.github/workflows/build.yaml

38 lines
1.3 KiB
YAML
Raw Normal View History

2024-01-22 18:05:05 +03:30
# This workflow will build an Arch Linux ISO file with the commit on it
2023-01-02 14:55:21 +03:30
name: build parchiso per release
2023-01-01 10:37:31 +03:30
on:
release:
types:
- created
2023-01-02 14:55:21 +03:30
2024-01-22 18:05:05 +03:30
env:
api_key: ${{ secrets.GITHUB_TOKEN }}
name: ${{ github.event.repository.name }}
release_name: ${{ github.ref_name }}
GH_TOKEN: ${{ github.token }}
2023-01-01 10:37:31 +03:30
jobs:
build:
2023-10-10 14:33:52 +03:30
permissions:
contents: write
2023-01-01 10:37:31 +03:30
runs-on: ubuntu-latest
container:
image: archlinux:latest
options: --privileged
steps:
- uses: actions/checkout@v3
- name: Install Packages via Pacman
2024-04-15 20:32:57 +03:30
run: pacman -Sy; pacman --noconfirm -S git archiso python python-pygithub github-cli reflector p7zip zip unzip
2024-01-22 18:05:05 +03:30
- name: Change Arch docker mirror
run: reflector -c "US" -f 12 -l 10 -n 12 --save /etc/pacman.d/mirrorlist
2023-01-01 10:37:31 +03:30
- name: Build image
run: mkarchiso -v iso/
- name: Upload iso to the release
2024-01-22 18:05:05 +03:30
run: |
cd ./out
mkdir iso_parts
# split -d -b 2000M "$(ls *.iso)" iso_parts/"$(ls *.iso)"_part
2024-04-15 19:19:39 +03:30
zip -s 1000m iso_parts/"$(ls *.iso)".zip "$(ls *.iso)"
#7z -v1000m a iso_parts/"$(ls *.iso)".zip "$(ls *.iso)"
2024-02-16 18:00:53 +03:30
md5sum iso_parts/* > iso_parts/md5sums.txt
2024-01-22 18:05:05 +03:30
gh release upload ${{ github.event.release.tag_name }} ./iso_parts/* -R ${{ github.repository }}