temporalio / helm-charts

Temporal Helm charts
MIT License
321 stars 343 forks source link

[Bug] temporal-cassandra domin name cannot be resolved #291

Closed kevin1995-xu closed 5 months ago

kevin1995-xu commented 2 years ago

What are you really trying to do?

report a bug

Describe the bug

pod stuck on container init even the temporal-cassandra is working find

temporal-admintools-6d54c4ccf-rhd5p 1/1 Running 0 8m17s temporal-cassandra-0 1/1 Running 0 8m17s temporal-frontend-8f59f594b-lqrx6 0/1 Init:1/4 0 8m17s temporal-history-7dfb5ff65-j4fjf 0/1 Init:1/4 0 8m17s temporal-matching-7fd865fbd4-xlbj6 0/1 Init:1/4 0 8m17s temporal-schema-setup-p6m5l 0/2 Init:1/4 0 8m17s temporal-web-78745cd865-bdlnt 1/1 Running 0 8m17s temporal-worker-cf5d58f6b-7cphl 0/1 Init:1/4 0 8m17s

and then i check the log on temporal-frontend 8d47094915873deca38d48a7779a2d5

seem it resolved the k8s host machine dns and connect a external IP

so i try to dig this domain name on my own pod image

temporal-cassandra.temporal.svc.cluster.local resolves to the correct address

seems k8s-dns is normal

temporal-cassandra hosts conf: image

And just for reference i fixed it by change the cassandra.host to FQDN

temporal-helm/templates/_helpers.tpl: line 320

{{/ All Cassandra hosts. /}} {{- define "cassandra.hosts" -}} {{- range $i := (until (int .Values.cassandra.config.cluster_size)) }} {{- $cassandraName := include "call-nested" (list $ "cassandra" "cassandra.fullname") -}} {{- printf "%s.%s.svc.cluster.local." $cassandraName $.Release.Namespace -}} {{- end }} {{- end -}}

{{/ The first Cassandra host in the stateful set. /}} {{- define "cassandra.host" -}} {{- $cassandraName := include "call-nested" (list . "cassandra" "cassandra.fullname") -}} {{- printf "%s.%s.svc.cluster.local." $cassandraName .Release.Namespace -}} {{- end -}}

but i m not sure the reason

pls help to check and confirm

Minimal Reproduction

Environment/Versions

Additional context

robholland commented 5 months ago

We no longer assume cluster.local which may help. Please re-open if this is still an issue.