Build and artifact ISO #10
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: Build and artifact ISO | |
on: | |
workflow_dispatch: | |
jobs: | |
build-customize-iso: | |
name: Build and customize ISO | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Install qemu-kvm | |
run: | | |
sudo apt-get install -y qemu-kvm | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
fetch-depth: 0 | |
- name: Generate changelog | |
run: | | |
changelog=$(make changelog | base64 -w0) | |
echo "CHANGELOG=${changelog}" >> $GITHUB_ENV | |
- name: Show changelog | |
run: | | |
echo ${{ env.CHANGELOG }} | base64 -d | |
- name: Build ISO | |
run: | | |
make cosa-init | |
make build-iso | |
make customize-iso | |
- name: Set ISO absolute path | |
run: | | |
iso_path=$(readlink -f $(dirname $(pwd))/cosa/builds/latest/x86_64/*.iso) | |
echo "ISO_PATH=${iso_path}" >> $GITHUB_ENV | |
- name: Upload artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: onp-${{ github.ref_name }}-x86_64.iso | |
path: ${{ env.ISO_PATH }} |