BorisPolonsky / dify-helm

Deploy langgenious/dify, an LLM based app on kubernetes with helm chart
MIT License
130 stars 29 forks source link

question help #66

Open hx2023222576 opened 1 month ago

hx2023222576 commented 1 month ago

mkdir: cannot create directory ‘/bitnami/postgresql/data’: Permission denied

Because it's my first time using it, I don't quite understand. After deployment, the log shows this. Can you help me solve it

BorisPolonsky commented 1 month ago

Please follow our issue template, otherwise we couldn't figure out what the problem is given what you've provided so far.

hx2023222576 commented 1 month ago

微信图片_20240513213931 The container PostgreSQL installed by Helm does not have permission

BorisPolonsky commented 1 month ago

This is what would happen under the hood according to bitnami

chown {{ .Values.primary.containerSecurityContext.runAsUser }}:{{ .Values.primary.podSecurityContext.fsGroup }} {{ .Values.primary.persistence.mountPath }}
mkdir -p {{ .Values.primary.persistence.mountPath }}/data {{- if (include "postgresql.v1.mountConfigurationCM" .) }} {{ .Values.primary.persistence.mountPath }}/conf {{- end }}
chmod 700 {{ .Values.primary.persistence.mountPath }}/data {{- if (include "postgresql.v1.mountConfigurationCM" .) }} {{ .Values.primary.persistence.mountPath }}/conf {{- end }}

So you have a container that allows chown, chmod but rejects chmod afterwards. Which kubernetes cloud service were used in your case?

The log level suggests warning instead of error. Did you rule out other causes as well. What does the event dashboard suggests?