Skip to content
codemowersPublic

About

Reusable GitHub Actions workflows

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 

Repository files navigation

Shared workflows

Reusable GitHub Actions workflows for Codemowers projects. Call them from a tagged version, for example @v2.2.0, and grant packages: write to the calling job.

  • oci-image.yaml builds linux/amd64 and linux/arm64 on native runners and scans both with Trivy. For v* tags it pushes each architecture by digest, joins the digests into an image index tagged with the release tag and commit SHA, and records NAME@DIGEST for the chart.
  • helm-chart.yaml lints and renders the chart on every call. For vMAJOR.MINOR.PATCH[-PRERELEASE] tags it replaces each image: NAME:latest values line with the image index digest from the same run, sets imageRegistry: ghcr.io/<owner>, and pushes the chart, versioned from the tag, to oci://ghcr.io/<owner>/charts. Keep Chart.yaml at a placeholder version such as 0.1.0 in Git.

Optional inputs: labels adds OCI labels, fail-on-severity (for example HIGH,CRITICAL) fails builds with fixable vulnerabilities, submodules is passed to checkout, and no-cache rebuilds every layer. For the chart, registry-key names the registry values key (default imageRegistry); set it empty to write full ghcr.io/<owner>/NAME@DIGEST references. Tagged chart runs also upload the package as the helm-chart artifact.

Several images: call oci-image.yaml once per image, for example from a matrix job, and list them all in images.

jobs:
  checks:
    runs-on: ubuntu-latest
    steps: []  # project tests
  image:
    needs: checks
    uses: codemowers/workflows/.github/workflows/oci-image.yaml@v2.2.0
    permissions: {contents: read, packages: write}
    with:
      image: example
  chart:
    needs: image
    uses: codemowers/workflows/.github/workflows/helm-chart.yaml@v2.2.0
    permissions: {contents: read, packages: write}
    with:
      images: example

Action and Helm versions are pinned here. Release changes under a new immutable tag; callers move to it once a tagged release has published cleanly.

About

Reusable GitHub Actions workflows

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors