Argo CD With Helm: Charts, Values, and Versioned Releases
83%
Upgrading the Helm Chart
Our goal is to upgrade the Helm chart to a new version, but this time we use a Helm repository. As in the previous example, we upgrade the chart by changing the image tag in values.yaml and updating the chart version in Chart.yaml.
# Update the image tag
sed -i 's/IMAGE_TAG=.*/IMAGE_TAG=v2/' $HOME/.bashrc
source $HOME/.bashrc
# Docker build with the new tag
docker build -t $IMAGE_REGISTRY:$IMAGE_TAG $HOME/todo/app
# Docker push with the new tag
docker push $IMAGE_REGISTRY:$IMAGE_TAG
Update values.yaml with the new image tag:
cat < $HOME/todo/app/manifests/helm/todo/values.yaml
# Set the replica count to 2 this time
replicaCount: 2
image:
repository: $IMAGE_REGISTRY
# This is the new image tag
tag: $IMAGE_TAG
pullPolicy: IfNotPresent
service:
type: NodePort
port: 5000
resources:
limits:
cpu: 100m
memory: 128Mi
requests:
cpu: 100m
memory: 128Mi
imagePullSecrets:
- name: gitlab-registry
readinessProbe:
httpGet:
path: /tasks
port: 5000
initialDelaySeconds: 5
periodSeconds: 10
autoscaling:
enabled: false
serviceAccount:
create: false
ingress:
enabled: false
httpRoute:
enabled: false
EOF
Update the chart version (version) and the app version (appVersion) in Chart.yaml:
cat < $HOME/todo/app/manifests/helm/todo/Chart.yaml
apiVersion: v2
name: todo
description: A Helm chart to install the todo app
type: application
versionGitOps the Hard Way, with Argo CD
Build Real GitOps Pipelines From Empty Clusters to Automated DeploysEnroll now to unlock all content and receive all future updates for free.
Unlock now $20.99$16.79Learn More
Hurry! This limited time offer ends in:
To redeem this offer, copy the coupon code below and apply it at checkout:
