https://dagster.io/ logo
#ask-community
Title
# ask-community
y

Yassine AIT BAHA

03/06/2023, 5:27 PM
Hi all, anyone testing helm chart deployment with external postgres database, how to use secret for postgresqlhost and postgresql password ? for example please
dagster bot responded by community 1
t

Tyler Eason

03/06/2023, 5:35 PM
here is a super basic thing I'm composing from memory and looking at docs:
Copy code
# kustomization.yaml
namespace: default

secretGenerator:
  - name: db-creds
    options:
      # this is necessary because dagster can't read the the suffixes and the k8s job will hang
      disableNameSuffixHash: true
    literals:
    # the password for postgresqlUsername when it is different of postgres
    - postgresql-postgres-password=password1
    # override postgresqlPassword
    - postgresql-password=password2
    # override replication.password
    - postgresql-replication-password=repl_password
    # will be sed to authenticate on LDAP
    - postgresql-ldap-password=

helmCharts:
- name: dagster
  repo: <https://dagster-io.github.io/helm>
  version: 1.1.20
  releaseName: dagster
  namespace: default
  valuesFile: path/to/values.yaml
values.yaml
Copy code
global:
  postgresqlSecretName: "db-creds"

postgresql:
  enabled: false
  postgresqlHost: <DB URL>
  postgresqlUsername: <Username, would match password1 in example>
  existingSecret: db-creds
naturally you should NOT leave your credentials just floating in yaml but this should get you started.
y

Yassine AIT BAHA

03/06/2023, 7:04 PM
Thanks @Tyler Eason 🙂
3 Views