GitHub user dosubot[bot] added a comment to the discussion: Production deployment issue in
<!-- Answer --> Your pods are still missing psycopg2 because the image tag in your values.yaml (`2.1.0`) does not match the tag you built and pushed (`4.1.2`). The Superset Helm chart uses the image and tag from values.yaml for all main pods—including init-db, worker, and web—so if the tag doesn’t match what you pushed, Kubernetes will use an old or default image, which won’t have your dependencies and will cause errors like `ModuleNotFoundError: No module named 'psycopg2'` [reference](https://github.com/apache/superset/blob/1a54b761c1870e61296e4af4da56dedf23b5e8e8/helm/superset/values.yaml). To fix this: 1. Change your values.yaml to use `tag: 4.1.2` (the tag you pushed). 2. Run `helm upgrade --install ...` again with `pullPolicy: Always`. 3. Check the image actually running in your pods with `kubectl get pods -n <namespace> -o wide` and `kubectl describe pod <pod-name> -n <namespace>`. The image should be `reddy2210/superset-custom:4.1.2`. 4. If you still see errors, run `docker run --rm -it reddy2210/superset-custom:4.1.2 python -c "import psycopg2"` locally to confirm psycopg2 is present in your image. Once the image tag matches and the image is correct, all pods (including init-db) will have the right dependencies and the psycopg2 error should disappear [reference](https://github.com/apache/superset/blob/1a54b761c1870e61296e4af4da56dedf23b5e8e8/helm/superset/templates/init-job.yaml). For production, always use Kubernetes Secrets for passwords and build all Python dependencies into your image before deploying. <!-- 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/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/31b8cb6a-8fe0-4180-b41b-a00b4d6dc8d9?feedback_type=other)</sup> [](https://go.dosu.dev/discord-bot) [](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-13600093 ---- 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]
