From 14cdac27d396ba5cf4fb7c0402c5ea208b19f544 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomislav=20Kopi=C4=87?= Date: Sun, 14 Sep 2025 13:46:36 +0200 Subject: [PATCH] Add lint and publuish steps for Helm chart --- .gitea/workflows/helm-lint.yaml | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/.gitea/workflows/helm-lint.yaml b/.gitea/workflows/helm-lint.yaml index 6cbf057..caeb171 100644 --- a/.gitea/workflows/helm-lint.yaml +++ b/.gitea/workflows/helm-lint.yaml @@ -1,23 +1,19 @@ -name: Test Helm Chart - -on: - push: - branches: - - main - pull_request: - -jobs: - helm-lint: + publish-helm: runs-on: docker container: image: alpine/helm:3.14.0 steps: - - name: Clone repo manually + - name: Clone repo run: | echo "Cloning repository $GITHUB_REPOSITORY..." - git clone "${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}.git" "$GITHUB_WORKSPACE" + git clone "https://${{ secrets.REPO_USER }}:${{ secrets.REPO_TOKEN }}@${GITHUB_SERVER_URL#https://}/${GITHUB_REPOSITORY}.git" $GITHUB_WORKSPACE cd "$GITHUB_WORKSPACE" - - name: Run Helm lint + - name: Lint and package Helm chart run: | - helm lint "$GITHUB_WORKSPACE/" + helm lint . + helm package . -d charts + + - name: Publish Helm chart + run: | + curl --user ${{ secrets.REPO_USER }}:${{ secrets.REPO_TOKEN }} -X POST --upload-file charts/duino-miner-0.1.1.tgz $GITHUB_SERVER_URL/api/packages/${{ secrets.REPO_USER }}/helm/api/charts