Files
kks-provider-plugin/.github/workflows/release-chart.yaml
T
josh b74fb06b87
Release Chart / release (push) Failing after 6s
deploy / build (push) Failing after 9m7s
feat: update actions
2026-07-22 23:08:55 +03:30

67 lines
1.7 KiB
YAML

name: Release Chart
on:
push:
branches:
- main
paths:
- charts/**
- .cr.yaml
- .github/workflows/release-chart.yaml
workflow_dispatch:
permissions:
contents: write
packages: write
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Configure Git
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "$GITHUB_ACTOR@users.noreply.github.com"
- name: Install Helm
uses: azure/setup-helm@v4
- name: Run chart-releaser
uses: helm/chart-releaser-action@v1.7.0
with:
charts_dir: charts
config: .cr.yaml
skip_existing: true
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
- name: Log in to registry
uses: docker/login-action@v3
with:
registry: registry.kloude.ir
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push chart to OCI registry
run: |
shopt -s nullglob
charts=(.cr-release-packages/*.tgz)
if [ ${#charts[@]} -eq 0 ]; then
echo "No packaged charts to push"
exit 0
fi
for chart in "${charts[@]}"; do
helm push "$chart" "oci://registry.kloude.ir/kloude/kks-provider-plugin-charts"
done
- name: Make OCI chart public
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh api --method PATCH "/orgs/kloude/kks-provider-plugin/packages/container/charts%2Fkks-provider-plugin/visibility" -f visibility=public || true