Problem to solve
I am setting up a CI/CD pipeline in GitLab specifically designed to include a Helm chart creation step. I want to ensure this part of the pipeline is general enough to be applied across various projects but adheres to best practices. I’m looking for advice or examples of how others have structured their Helm chart creation within a CI/CD pipeline.
Steps to reproduce
I have followed the basic Helm chart tutorials and documentation. Currently, my .gitlab-ci.yml
includes a basic pipeline but without the Helm chart integration. I am looking to expand it with best practices.
Configuration
Here’s a snippet of my current .gitlab-ci.yml
(sensitive info has been omitted):
stages:
- build-gradle
- build-image
- artifact
# - helm
- deploy
- release
build_job:
stage: build
script:
- echo "Building application"
deploy_job:
stage: deploy
script:
- helm upgrade --kubeconfig=$ADA_KUBE_CONF --install $CONTAINER_NAME ./$CONTAINER_NAME -f $CONTAINER_NAME/release-values.yml --namespace $NS --create-namespace --set image.repository=$DOCKER_REGISTRY/$CONTAINER_NAME,image.tag=$CI_COMMIT_SHORT_SHA-$CI_COMMIT_REF_NAME
Thanks for taking the time to be thorough in your request, it really helps!