Skip to content

Day 94/100 commits - Create git service and checkout object based on … #10

Day 94/100 commits - Create git service and checkout object based on …

Day 94/100 commits - Create git service and checkout object based on … #10

Workflow file for this run

name: Go
on:
push:
branches:
- main
paths-ignore:
- "README.md"
- "docs/**"
- ".github/**"
- ".img/**"
- "config.yaml"
- "dockerfile"
- ".dockerignore"
- ".gitignore"
- "LICENSE"
release:
types: [created]
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Git Version
id: version
uses: paulhatch/[email protected]
with:
tag_prefix: "v"
version_format: ${{ github.event_name == 'release' && '${major}.${minor}.${patch}' || '${major}.${minor}.${patch}-prerelease${increment}' }}
- name: Setup buildx
uses: docker/setup-buildx-action@v3
- name: Run make
run: |
VERSION=${{ steps.version.outputs.version }} make docker-build
- name: Login to GitHub Container Registry
if: github.event_name == 'push' || github.event_name == 'release'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Publish Image
if: github.event_name == 'push' || github.event_name == 'release'
run: |
VERSION=${{ steps.version.outputs.version }} make docker-push
- name: Publish Helm Chart
if: github.event_name == 'push' || github.event_name == 'release'
run: |
VERSION=${{ steps.version.outputs.version }} make helm-push