# Regarding build steps, this is a copy of the Dockerfile and should be kept in-sync name: "Build pumptools" on: push: branches: - ci-github release: types: - created workflow_dispatch: # allows you to trigger manually # TODO check github actions doc to evaluate if we need this or if this is even a good idea # concurrency: # group: ${{ github.workflow }}-${{ github.ref }} # cancel-in-progress: true jobs: build: runs-on: "ubuntu-20.04" steps: - name: "Checkout repository" uses: "actions/checkout@v2" # Building bootstrapped using docker containers - name: "Install prerequisites" run: | sudo apt-get update sudo apt-get install -y runc containerd docker.io - name: "Build" run: | make build-docker # Do some unpacking of the dist zip. Artifact upload repackages stuff - name: "Prepare artifact package" run: | mkdir artifact cd artifact unzip ../build/docker/pumptools-public.zip cd .. - name: "Upload artifact" uses: "actions/upload-artifact@v2" with: name: pumptools-${{ github.sha }} retention-days: 30 if-no-files-found: "error" path: | artifact/** publish-release: needs: "build" runs-on: "ubuntu-20.04" steps: # This already extracts the contents of the artifact - name: "Download artifact" uses: "actions/download-artifact@v2" with: name: pumptools-${{ github.sha }} - name: "show dir" run: | pwd ls -la - name: "Publish release" uses: "marvinpinto/action-automatic-releases@v1.2.1" with: repo_token: "${{ secrets.GITHUB_TOKEN }}" automatic_release_tag: "latest" prerelease: true title: master ${{ github.sha }} files: | artifact/**