Skip to content

Custom OAuth config not created even if all env vars are set #10420

@saplla

Description

@saplla

Description:

Installing Rocket Chat with a Helm chart, I'm specifying all the required variables to configure a custom OAuth provider as environment variables. E.g. I create env vars called:

  Accounts_OAuth_Custom-Keycloak: true
  Accounts_OAuth_Custom-Keycloak-url: https://example.com/auth
  ...

When I log into the Rocket Chat, no custom OAuth provider called Keycloak has been created. But if I create one called Keycloak, it populates all the fields from the env vars I supplied. This is preventing me automating the deployment of Rocket Chat with Helm.

Server Setup Information:

  • Version of Rocket.Chat Server: rocket.chat:0.62.2 (docker hub image)
  • Operating System: N/A (kubernetes)
  • Deployment Method(snap/docker/tar/etc): helm
  • Number of Running Instances: 1
  • DB Replicaset Oplog: n/a
  • Node Version: unknown
  • mongoDB Version: mongodb:0.4.15 (docker hub image)

Steps to Reproduce:

  1. Clone https://github.com/kubernetes/charts/tree/master/stable/rocketchat, and add the following to values.yaml:
config:
  Accounts_OAuth_Custom-Keycloak: true
  Accounts_OAuth_Custom-Keycloak-url: https://example.com/my-auth
  Accounts_OAuth_Custom-Keycloak-token_sent_via: Header
  1. Install with helm
  2. Log in as an admin. Go to Administration -> oauth. No custom provider called Keycloak will exist.
  3. Create a custom provider and call it Keycloak. The values will be populated from the above config values.

Expected behavior:

Rocket chat should notice that env vars for the custom provider exist and should create the custom provider automatically.

Actual behavior:

The custom provider needs to be created manually, but then it loads values supplied as env vars.

Relevant logs:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions