diff --git a/.github/workflows/publish-helm-chart.yaml b/.github/workflows/publish-helm-chart.yaml index 22a8c70..618cb50 100644 --- a/.github/workflows/publish-helm-chart.yaml +++ b/.github/workflows/publish-helm-chart.yaml @@ -29,6 +29,34 @@ jobs: - name: Run Helm Unit Tests run: helm unittest chart --strict + - name: Create kind cluster + uses: helm/kind-action@v1 + + - uses: docker/build-push-action@v6 + name: Build current image as base for Angular example + if: ${{ steps.target_tags.outputs.tags != '' }} + with: + context: . + push: false + pull: true + tags: "codecentric/single-page-application-server:1-nginx-stable-alpine" + build-args: NGINX_TAG=stable-alpine + + - uses: docker/build-push-action@v6 + name: Build Angular example image + if: ${{ steps.target_tags.outputs.tags != '' }} + with: + context: examples/angular + push: false + pull: false + tags: "angular-example:latest" + + - name: Copy image to kind node + run: kind load docker-image "angular-example:latest" + + - name: Run chart-testing in kind + run: ct install --config chart/ci/ct.yaml + - name: Package Helm Chart run: helm package chart -u --version ${{ steps.get_latest_version.outputs.version }} --destination . diff --git a/chart/ci/ct-values.yaml b/chart/ci/ct-values.yaml new file mode 100644 index 0000000..b7ba722 --- /dev/null +++ b/chart/ci/ct-values.yaml @@ -0,0 +1,6 @@ +pod: + container: + image: + repository: angular-example + tag: latest + pullPolicy: IfNotPresent diff --git a/chart/ci/ct.yaml b/chart/ci/ct.yaml new file mode 100644 index 0000000..ef758e6 --- /dev/null +++ b/chart/ci/ct.yaml @@ -0,0 +1,4 @@ +charts: "chart" +validate-maintainers: true +validate-yaml: true +debug: true