dagster-io/dagster

Dagster Helm Chart: During install permission denied for schema public

Closed this issue · 2 comments

Dagster version

1.7.x

What's the issue?

Im deploying a new instance of dagster with external postgresql. in the values.yaml i set:

postgresql:
  enabled: false
  postgresqlHost: "myshost"
  postgresqlUsername: "myuser" 
  # https://github.com/helm/charts/issues/12836#issuecomment-524552358
  postgresqlPassword: "mypassword"
  postgresqlDatabase: "dagster"
  # set postgresql parameter keywords for the connection string.
  # see: https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-PARAMKEYWORDS
  postgresqlParams: 
    sslmode: disable

  postgresqlScheme: ""

  service:
    port: 5432
generatePostgresqlPasswordSecret: true

why the install is trying to create tables on public? the install processs works on my dev environment adding the user as "superuser". i dont really want the dagster account to run under superuser and create tables on "public".
i set up in the yaml value the database of dagster.

Error log:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1967, in _exec_single_context
self.dialect.do_execute(
File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/default.py", line 924, in do_execute
cursor.execute(statement, parameters)
psycopg2.errors.InsufficientPrivilege: permission denied for schema public
LINE 2: CREATE TABLE secondary_indexes (
^
The above exception was the direct cause of the following exception:
Traceback (most recent call last):

What did you expect to happen?

Run successfull install dagster on postgresql without superuser access

How to reproduce?

  1. external postgresql
  2. create schema "dagster"
  3. add all permisions to user "dagster" to schema "dagster"
  4. run the chart

Deployment type

Dagster Helm chart

Deployment details

No response

Additional information

No response

Message from the maintainers

Impacted by this issue? Give it a 👍! We factor engagement into prioritization.

fixed with:
CREATE SCHEMA dagster;
ALTER ROLE x_svc_dagster_test SET search_path TO dagster;;

works now.