Skip to content

Commit

Permalink
update workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
BarryBoot committed Apr 25, 2024
1 parent a28f01d commit 35f9d7e
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 5 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/code-scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: code-scan

on:
push:
branches:
- main
pull_request:

jobs:
scan-code:
uses: {{ vars.ORGANISATION_WORKFLOW_PATH }}/scan-code.yml@main
14 changes: 9 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,29 @@
name: build-scan
on:

on:
push:
branches:
- main
- develop
- devops-update

permissions:
contents: read
packages: write
security-events: write

env:
CARGO_TERM_COLOR: always

jobs:
build:
uses: ablockofficial/workflows/.github/workflows/build.yml@main
uses: {{ vars.ORGANISATION_WORKFLOW_PATH }}/build.yml@main
with:
REGISTRY: ${{ vars.REGISTRY }}
REPOSITORY: ${{ vars.REPOSITORY }}
NODE_TYPE: ${{ vars.NODE_TYPE }}
scan-image:
uses: ablockofficial/workflows/.github/workflows/scan-image.yml@main
uses: {{ vars.ORGANISATION_WORKFLOW_PATH }}/scan-image.yml@main
secrets: inherit
needs: build
with:
IMAGE: ${{ vars.REGISTRY }}/${{ vars.REPOSITORY }}:${{ github.sha }}
IMAGE: ${{ vars.REGISTRY }}/${{ vars.ORGANISATION_NAME }}/node-${{ vars.NODE_TYPE }}:${{ github.sha }}
17 changes: 17 additions & 0 deletions .github/workflows/manual-build-and-push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: manual-build-and-push

permissions:
contents: read
packages: write
security-events: write

env:
CARGO_TERM_COLOR: always

jobs:
build:
uses: {{ vars.ORGANISATION_WORKFLOW_PATH }}/build.yml@main
with:
REGISTRY: ${{ vars.REGISTRY }}
REPOSITORY: ${{ vars.REPOSITORY }}
NODE_TYPE: ${{ inputs.node_type }}
17 changes: 17 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: build-and-push

on:
release:
types: [published]

permissions:
contents: read
packages: write
security-events: write

jobs:
build:
uses: {{ vars.ORGANISATION_WORKFLOW_PATH }}/build.yml@main
with:
REGISTRY: ${{ vars.REGISTRY }}
REPOSITORY: ${{ vars.REPOSITORY }}

0 comments on commit 35f9d7e

Please sign in to comment.