GitHub user dosubot[bot] added a comment to the discussion: Production 
deployment issue in

<!-- Answer -->
For production, never hardcode your database password in values.yaml. Instead, 
create a Kubernetes Secret and reference it in your Helm config. For Superset, 
you can do this by either:

- Using supersetNode.connections.db_pass and setting its value from a Secret 
(recommended for external DBs), or
- For the internal PostgreSQL chart, using postgresql.auth.existingSecret.

Example: create a Secret with your password:

```yaml
apiVersion: v1
kind: Secret
metadata:
  name: superset-db-secret
type: Opaque
stringData:
  db_pass: "YOUR_STRONG_PASSWORD"
```

Then in your values.yaml:

```yaml
supersetNode:
  connections:
    db_host: appsqlsscind01.private.postgres.database.azure.com
    db_port: "5432"
    db_user: sspsqladmin
    db_pass: {{ .Values.db_pass | quote }}
    db_name: superset

envFromSecrets:
  - superset-db-secret
```

Or, if you want Helm to manage the secret, use extraSecretEnv:

```yaml
extraSecretEnv:
  DB_PASS: "YOUR_STRONG_PASSWORD"
```

But it's safer to use an external Secret and reference it, so your password 
isn't in version control or Helm history. The same approach works for the 
Superset SECRET_KEY—store it in a Secret and reference it via 
extraSecretEnv.SUPERSET_SECRET_KEY or configOverrides.secrets. See more in the 
[Helm chart 
docs](https://github.com/apache/superset/blob/1a54b761c1870e61296e4af4da56dedf23b5e8e8/helm/superset/values.yaml)
 and [discussion](https://github.com/apache/superset/discussions/33941).


<!-- Dosu Comment Footer -->
*To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*

---
<sup>How did I do? 
[Good](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=great_response)
 | 
[Irrelevant](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=irrelevant_answer)
 | 
[Incorrect](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=incorrect_sources)
 | 
[Verbose](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=hallucination)
 | [Report 
🐛](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/d5bed106-fecc-4e7f-95d8-873a8b82314e?feedback_type=other)</sup>&nbsp;&nbsp;[![Join
 
Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Sh
 are on 
X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/discussions/33957)

GitHub link: 
https://github.com/apache/superset/discussions/33957#discussioncomment-13599791

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to