Skip to content

Merge pull request #368 from kubewharf/dependabot/go_modules/k8s.io/c… #252

Merge pull request #368 from kubewharf/dependabot/go_modules/k8s.io/c…

Merge pull request #368 from kubewharf/dependabot/go_modules/k8s.io/c… #252

Workflow file for this run

name: Publish helm chart
on:
push:
tags: "*"
branches: ["main"]
jobs:
publish-scan:
name: Build scan image
runs-on: [ubuntu-20.04]
if: ${{ github.ref_type == 'tag' }}
steps:
- uses: actions/checkout@v3
- name: Docker login for ghcr
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Set image tag for release
id: tag-name
run: echo "IMAGE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- run: docker build -t ghcr.io/kubewharf/kelemetry-scan:${{steps.tag-name.outputs.IMAGE_TAG}} scan
- run: docker push ghcr.io/kubewharf/kelemetry-scan:${{steps.tag-name.outputs.IMAGE_TAG}}
publish-chart:
name: Build helm chart
runs-on: [ubuntu-20.04]
if: ${{ github.ref_type == 'tag' }}
steps:
- uses: actions/checkout@v3
- name: Docker login for ghcr
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Set image tag for release
id: tag-name
run: echo "IMAGE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- run: helm package charts/kelemetry --app-version="${{steps.tag-name.outputs.IMAGE_TAG}}" --version="${{steps.tag-name.outputs.IMAGE_TAG}}" -d output
- run: helm push output/kelemetry-chart-${{steps.tag-name.outputs.IMAGE_TAG}}.tgz oci://ghcr.io/kubewharf