BorisPolonsky / dify-helm

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

Explicitly Include Affinity & Toleration Options in PostgresSQL #71

Closed Shomu-Maersk closed 4 months ago

Shomu-Maersk commented 4 months ago

Thanks for the wonderful helm solution so that anyone can deploy Dify in Kubernetes. That being said I have identified an issue where the repository lacked example values for tolerations and affinity for the Postgres (master & replicas) deployment. This PR includes an updated values.yaml file with a commented example showcasing how to configure these settings for the Postgres database. Best Shomu

BorisPolonsky commented 4 months ago

Thanks for your contribution. Things look good to me but by kubernetes developing environment went down so I can't test it ASAP. BTW, Postgresql were from bitnami/charts I wonder if we shall directly quote their comments in our .Values.yaml so that users knows where to look at in case they have problems.

Comments for primary https://github.com/bitnami/charts/blob/e94387a3f24d5a4f920b31dbe83997e3a524be2e/bitnami/postgresql/values.yaml#L559-L562 https://github.com/bitnami/charts/blob/e94387a3f24d5a4f920b31dbe83997e3a524be2e/bitnami/postgresql/values.yaml#L567-L570 Comments for replicas https://github.com/bitnami/charts/blob/e94387a3f24d5a4f920b31dbe83997e3a524be2e/bitnami/postgresql/values.yaml#L567-L570 https://github.com/bitnami/charts/blob/e94387a3f24d5a4f920b31dbe83997e3a524be2e/bitnami/postgresql/values.yaml#L1011-L1014

Shomu-Maersk commented 4 months ago

PR updated as per comments.

BorisPolonsky commented 4 months ago

Hello there. The comments here suggests primary but indeed they are for readReplicas. Please update them as follow:

  ## @param readReplicas.tolerations Tolerations for PostgreSQL read only pods assignment
  ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
  ##
  tolerations: []
Shomu-Maersk commented 4 months ago

Hi @BorisPolonsky, updated the PR with readReplicas.tolerations. Best Shomu