Skip to content

Admin user not created on first install with custom Postgres #66

@vcanuel

Description

@vcanuel

Hi,

When installing Directus via the Helm chart on Kubernetes with a custom Postgres instance, everything seems to deploy correctly, but the admin user is not created on first install.

Here are the relevant values I’m using:

adminEmail: "directus-admin@example.com"
createApplicationSecret: true
applicationSecretName: "directus-application-secret"
databaseEngine: "postgresql"
createPostgresqlSecret: false
createMysqlSecret: false
mysql:
  enableInstallation: false
postgresql:
  enableInstallation: false
  auth:
    existingSecret: "directus-postgresql-secret"
    database: "directus_postgres"
    username: "directus_postgres"
  postgresqlURL: "db-service"

I checked the database: directus_roles is correctly populated, but directus_users is empty.

There’s no error during the installation, but once the pod is running, Directus has no user, and I need to create one manually using the CLI:

npx directus users create \
  --email directus-admin@example.com \
  --password 'XXXXX' \
  --role <UUID_ADMIN_ROLE>

Expected behavior: the admin user defined via the adminEmail value and ADMIN_PASSWORD in the secret referenced by applicationSecretName should be created automatically.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    defectSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions