Skip to content

Build and release ISO #15

Build and release ISO

Build and release ISO #15

Workflow file for this run

name: Build and release ISO
on:
workflow_dispatch:
push:
branches:
- master
schedule:
- cron: "0 0 1 * *"
jobs:
build:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile --tag build:latest
- name: Run container and build ISO
run: |
docker run --volume ${{ github.workspace }}:/repo --privileged --name build build:latest
mv live-image-amd64.iso rTS_RescueMedia.iso
- name: Tag the repository
id: tag
run: |
# See https://docs.github.com/en/get-started/using-git/dealing-with-special-characters-in-branch-and-tag-names
TAG=v$(date -Iseconds | sed 's/[T:\+]/-/g')
echo "$TAG"
echo "tag=$TAG" >> $GITHUB_OUTPUT
git config user.name "GitHub Action"
git config user.email "[email protected]"
git tag -a $TAG -m "Published version $TAG" ${GITHUB_SHA}
git push origin $TAG
- name: Upload release to GitHub
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/') != true
with:
files: ./rTS_RescueMedia.iso
prerelease: false
tag_name: ${{ steps.tag.outputs.tag }}
generate_release_notes: true
- name: Release new Version
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: ./rTS_RescueMedia.iso
generate_release_notes: true