immich-app / immich-charts

Helm chart implementation of Immich
https://immich.app
GNU Affero General Public License v3.0
107 stars 45 forks source link

Add other based image #38

Closed oslo254804746 closed 1 year ago

oslo254804746 commented 1 year ago

Is there a plan to provide other based( like slim-buster...) image?

I want to use exist redis and postgres-sql, but it Looks like there is a dns resolution problem(alpine)

/usr/src/app # ping postgres-postgresql.app.svc.cluster.local
PING postgres-postgresql.app.svc.cluster.local (3.64.163.50): 56 data bytes
^C
--- postgres-postgresql.app.svc.cluster.local ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss
/usr/src/app # ping postgres-postgresql.app.svc.cluster.local
PING postgres-postgresql.app.svc.cluster.local (3.64.163.50): 56 data bytes
^C
--- postgres-postgresql.app.svc.cluster.local ping statistics ---
/usr/src/app # ping redis.app.cluster.svc.local
PING redis.app.cluster.svc.local (3.64.163.50): 56 data bytes
^C
--- redis.app.cluster.svc.local ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss
/usr/src/app # ping redis.app.cluster.svc.local
PING redis.app.cluster.svc.local (3.64.163.50): 56 data bytes
^C
--- redis.app.cluster.svc.local ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss
/usr/src/app # ping redis.app.cluster.svc.local
PING redis.app.cluster.svc.local (3.64.163.50): 56 data bytes
^C
--- redis.app.cluster.svc.local ping statistics ---
1 packets transmitted, 0 packets received, 100% packet loss
/usr/src/app # ping redis.app.cluster.svc.local
PING redis.app.cluster.svc.local (3.64.163.50): 56 data bytes
^C
--- redis.app.cluster.svc.local ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss
bo0tzz commented 1 year ago

This doesn't look like the sort of DNS issue that would be caused by Alpine, as it is resolving postgres-postgresql.app.svc.cluster.local to an address, just (probably) not a correct one. Are you sure your cluster networking/DNS setup are sound?

oslo254804746 commented 1 year ago

my cluster config is correct, and I have many running containers use this config I follow pages like this edit /etc/resolve.conf and it worked

❯ kubectl exec -it immich-microservices-66d5546b56-m6wpw -n app -- sh
/usr/src/app # cat /etc/resolv.conf
nameserver 169.254.25.10
search app.svc.cluster.local svc.cluster.local cluster.local cn
options ndots:5
/usr/src/app # ping redis-master.app.svc.cluster.local
PING redis-master.app.svc.cluster.local (3.64.163.50): 56 data bytes
^C
--- redis-master.app.svc.cluster.local ping statistics ---
2 packets transmitted, 0 packets received, 100% packet loss
/usr/src/app # vi /etc/resolv.conf
/usr/src/app # cat /etc/resolv.conf
nameserver 169.254.25.10
search app.svc.cluster.local svc.cluster.local cluster.local cn
#options ndots:5
/usr/src/app # ping redis-master.app.svc.cluster.local
PING redis-master.app.svc.cluster.local (10.233.14.36): 56 data bytes
64 bytes from 10.233.14.36: seq=0 ttl=64 time=0.080 ms
64 bytes from 10.233.14.36: seq=1 ttl=64 time=0.095 ms
64 bytes from 10.233.14.36: seq=2 ttl=64 time=0.134 ms
^A^A^A^A^A^A64 bytes from 10.233.14.36: seq=3 ttl=64 time=0.132 ms
^C
--- redis-master.app.svc.cluster.local ping statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 0.080/0.110/0.134 ms
/usr/src/app #
bo0tzz commented 1 year ago

Do you have a searchdomain configured in the resolv.conf on the kubernetes worker node? (So not in a pod)

oslo254804746 commented 1 year ago

No, Before this issue I use default config add

dnsConfig:
  options:
  - name: ndots
    value: "3"

into templates/server.yaml,templates/microservices.yaml solved this problem