diff --git a/.github/workflows/push-docker.yml b/.github/workflows/push-docker.yml index 50d03bcc..7c715bc2 100644 --- a/.github/workflows/push-docker.yml +++ b/.github/workflows/push-docker.yml @@ -140,3 +140,7 @@ jobs: tags: ${{ steps.meta3.outputs.tags }} labels: ${{ steps.meta3.outputs.labels }} platforms: linux/amd64,linux/arm64/v8 + - name: Build and Push Helm Chart + run: | + helm package chart/stirling-pdf + helm push stirling-pdf-chart-1.0.0.tgz oci://registry-1.docker.io/frooodle diff --git a/Jenkinsfile b/Jenkinsfile index dce948a4..d3cbe2c8 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -22,12 +22,24 @@ pipeline { def appVersion = sh(returnStdout: true, script: './gradlew printVersion -q').trim() def image = "frooodle/s-pdf:$appVersion" withCredentials([string(credentialsId: 'docker_hub_access_token', variable: 'DOCKER_HUB_ACCESS_TOKEN')]) { - sh "docker login --username frooodle --password $DOCKER_HUB_ACCESS_TOKEN" + sh "docker login --username frooodle --password $DOCKER_HUB_ACCESS_TOKEN" sh "docker push $image" } } } - - } - } + } + stage('Helm Push') { + steps { + script { + //TODO: Read chartVersion from Chart.yaml + def chartVersion = '1.0.0' + withCredentials([string(credentialsId: 'docker_hub_access_token', variable: 'DOCKER_HUB_ACCESS_TOKEN')]) { + sh "docker login --username frooodle --password $DOCKER_HUB_ACCESS_TOKEN" + sh "helm package chart/stirling-pdf" + sh "helm push stirling-pdf-chart-1.0.0.tgz oci://registry-1.docker.io/frooodle" + } + } + } + } + } } \ No newline at end of file diff --git a/chart/stirling-pdf/Chart.yaml b/chart/stirling-pdf/Chart.yaml index 3482b36d..a69894a0 100644 --- a/chart/stirling-pdf/Chart.yaml +++ b/chart/stirling-pdf/Chart.yaml @@ -9,7 +9,7 @@ keywords: maintainers: - name: Frooodle url: https://github.com/Frooodle/Stirling-PDF -name: stirling-pdf +name: stirling-pdf-chart sources: - https://github.com/Frooodle/Stirling-PDF version: 1.0.0