Skip to content

initial commit

initial commit #1

Workflow file for this run

# This workflow is the main workflow on pushing to the main branch
# and runs builds, releases, conventional commits, and pushes.
name: Main
on:
push:
branches: [ main ]
jobs:
build-node:
uses: ./.github/workflows/build-node.yml
build-image:
uses: ./.github/workflows/build-image.yml
needs: build-node
with:
tagTypes: |
type=sha
snyk:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Run Snyk to check for vulnerabilities
uses: snyk/actions/node@master
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
release:
runs-on: ubuntu-latest
needs: [build-image, snyk]
outputs:
changed: ${{ steps.tag.outputs.changed }}
newVersion: ${{ steps.tag.outputs.newVersion }}
steps:
- name: Checkout code with commit history
uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: liatrio/[email protected]
id: tag
with:
debug: true
env:
GITHUB_TOKEN: ${{ secrets.LIATRIO_BOT_PRIVATE_REPO_ACCESS_PAT }}
publish-image:
uses: ./.github/workflows/build-image.yml
needs: release
if: needs.release.outputs.changed == 'true'
with:
tagTypes: |
type=semver,pattern={{version}},value=${{ needs.release.outputs.newVersion }}
type=raw,value=latest,enable=${{ github.ref == format('refs/heads/{0}', 'main') }}