argo-helm icon indicating copy to clipboard operation
argo-helm copied to clipboard

ArgoCD chart issue when using netpols with redis-ha and haproxy

Open pmcgrath-mck opened this issue 2 months ago • 4 comments

Describe the bug

When trying to upgrade to the latest version (9.1.0) which depends on redis-ha 4.34.11, seeing an issue with enabling netpol for redis-ha haproxy

Can see with this

helm template argocd -n argocd argo/argo-cd --version 9.1.0 \
  --set redis-ha.enabled=true \
  --set redis-ha.haproxy.enabled=true \
  --set redis-ha.haproxy.networkPolicy.enabled=true \
  --set redis-ha.haproxy.networkPolicy.ingressRules[0].selectors[0].podSelector.matchLabels.app\.kubernetes\.io/instance=argo-cd

Error: template: argo-cd/charts/redis-ha/templates/redis-haproxy-network-policy.yaml:64:12: executing "argo-cd/charts/redis-ha/templates/redis-haproxy-network-policy.yaml" at <include "redis-ports" .>: error calling include: template: argo-cd/charts/redis-ha/templates/_helpers.tpl:138:22: executing "redis-ports" at <.Values.redis.port>: nil pointer evaluating interface {}.redis

This has been fixed in this redis-ha release https://github.com/DandyDeveloper/charts/releases/tag/redis-ha-4.34.13

  • Bug fix is https://github.com/DandyDeveloper/charts/pull/353

Related helm chart

argo-cd

Helm chart version

9.1.0

To Reproduce

Can see it works with the new redis-ha version with

helm template redis-ha dandydev/redis-ha --version 4.35.0 \
  --set haproxy.enabled=true \
  --set haproxy.networkPolicy.enabled=true \
  --set haproxy.networkPolicy.ingressRules[0].selectors[0].podSelector.matchLabels.app\.kubernetes\.io/instance=argo-cd | \
  yq 'select(.kind == "NetworkPolicy")' | \
  head -n 10
---
# Source: redis-ha/templates/redis-haproxy-network-policy.yaml
kind: NetworkPolicy
apiVersion: networking.k8s.io/v1
metadata:
  name: redis-ha-haproxy-network-policy
  namespace: "default"
  labels:
    app: redis-ha
    heritage: "Helm"

Can see same issue we were seeing with the version the 9.1.0 argo-cd chart uses with

helm template redis-ha dandydev/redis-ha --version 4.34.11 \
  --set haproxy.enabled=true \
  --set haproxy.networkPolicy.enabled=true \
  --set haproxy.networkPolicy.ingressRules[0].selectors[0].podSelector.matchLabels.app\.kubernetes\.io/instance=argo-cd
Error: template: redis-ha/templates/redis-haproxy-network-policy.yaml:64:12: executing "redis-ha/templates/redis-haproxy-network-policy.yaml" at <include "redis-ports" .>: error calling include: template: redis-ha/templates/_helpers.tpl:138:22: executing "redis-ports" at <.Values.redis.port>: nil pointer evaluating interface {}.redis

Expected behavior

If the redis-ha is bumped to 4.35.0+ i think this will no longer be an issue and we can continue using netpols

Screenshots

No response

Additional context

No response

pmcgrath-mck avatar Nov 05 '25 17:11 pmcgrath-mck

Hi @pmcgrath-mck , we follow upstream's manifests and the versions between upstream and argo-helm are same, which means this is the ideal situation. Ref: https://github.com/argoproj/argo-cd/blob/v3.2.0/manifests/ha/base/redis-ha/chart/requirements.lock

Please open an issue in upstream about it if you hurry. Once upstream releases the version up as a specific version (not just merging into master branch), we will follow it as soon as possible.

yu-croco avatar Nov 06 '25 11:11 yu-croco

Thanks

I can wait, just posted so if anyone else sees the same issue with redis-ha usage with ArgoCD

They seem to already have a release, see https://github.com/DandyDeveloper/charts/releases

Checked with

$ helm repo add dandydev https://dandydeveloper.github.io/charts

$ helm search repo redis-ha
NAME             	CHART VERSION	APP VERSION	DESCRIPTION                                       
dandydev/redis-ha	4.35.2       	8.2.2      	This Helm chart provides a highly available Red...

Any upstream version that is v4.35+ seems to have already sorted this issue

pmcgrath avatar Nov 06 '25 23:11 pmcgrath

Yes, i have exactly the same issue when updating the argocd helmchart

Doubleth1nk avatar Nov 24 '25 09:11 Doubleth1nk

It seems passing the whole configuration into the redis-ha part is not working anymore. I forced to migrate into the single redis node deployment.

1995parham avatar Nov 24 '25 09:11 1995parham