Skip to main content
In this guide we’ll show how to add test users to Dex (the OpenID Connect provider deployed with Kubeflow) so you can verify profiles and permissions in Kubeflow. Kubeflow itself does not manage user accounts; authentication is handled by an external identity provider (IDP). For this demo we use the Dex instance already deployed with Kubeflow to create a few static users. This keeps the example self-contained and avoids configuring Google, GitHub, or other third-party providers.
Do not use static passwords or static password configuration in production. This approach is for local testing and demos only.
Prerequisites:
  • Kubectl configured for the cluster that hosts Kubeflow (RBAC permissions to view/edit resources in the auth namespace).
  • A local editor configured for kubectl edit or an ability to export and reapply a ConfigMap.
  • htpasswd (from Apache tools) for generating bcrypt hashes, or another bcrypt tool.

Overview

High-level steps:
  1. Inspect the cluster and locate Dex resources in the auth namespace.
  2. Export or edit the Dex ConfigMap (dex) and find data.config.yaml.
  3. Generate unique userID values and bcrypt password hashes.
  4. Add entries under staticPasswords and save the ConfigMap.
  5. Restart the Dex deployment to pick up changes.
  6. Log in via the Kubeflow / Dex page and verify authentication; mapping to Kubeflow profiles (namespaces) is a separate step.

Inspect the cluster

Use these commands to confirm Dex is running in the auth namespace and to export the ConfigMap for editing:
Useful kubectl commands (quick reference): A trimmed example of kubectl get all -n auth (illustrative):

Locate the Dex configuration

Open the exported dex.yaml or view the data.config.yaml field from the ConfigMap. The Dex configuration is embedded at data.config.yaml. Dex supports a staticPasswords section you can populate with local users. Example excerpt:

Add static users

Each entry under staticPasswords should include the following required fields: Generate a unique userID (you can use a timestamp or UUID). Example (timestamp):
Generate a bcrypt password hash. On Debian/Ubuntu install the Apache utilities (provides htpasswd):
On macOS with Homebrew install the Apache httpd package:
Create a bcrypt hash for the password (replace password123 with your desired password):
Note: The htpasswd command prints a leading colon; tr -d ':\n' removes that and the newline so you get only the hash.

Edit the Dex ConfigMap

You can edit the ConfigMap directly:
Under data.config.yaml → staticPasswords, add your entries using the bcrypt hashes and userIDs generated above. Example:
Save and exit your editor.

Apply changes: restart Dex

After editing the ConfigMap, restart the Dex deployment so the running pod will mount the new configuration:

Log in via Kubeflow / Dex

After Dex restarts, open the Kubeflow login page (the cluster’s Kubeflow address) and sign in using one of the new accounts. Example credentials used in this demo:
  • Email: john@example.com
  • Password: password123
A web browser window showing a centered "Log in to Your Account" form (Email Address and Password fields) with a "Login" button and a "dex" logo in the top left. The email field contains the text "john".
If you sign in as john@example.com (or mark@example.com), authentication will succeed, but you will not see any selectable Kubeflow profiles (namespaces) because those accounts are not yet mapped to Kubeflow profiles. The default example user (user@example.com) was created when Kubeflow deployed a demo profile and is mapped to the kubeflow-user-example-com profile/namespace; that user can select and operate in that namespace:
A screenshot of the Kubeflow web dashboard showing the namespace "kubeflow-user-example-com" with a left navigation bar and dashboard panels. The main area lists actions like creating notebooks, recent pipelines, and documentation links.

Next steps

  • To give a user access to a Kubeflow profile, map their identity (email / userID) to a Kubeflow Profile (which corresponds to a Kubernetes namespace). See Kubeflow Profiles and Multi-Tenancy documentation for details.
  • Consider integrating a managed IDP (OIDC/LDAP/GitHub/Google) for production authentication rather than using static passwords.
Summary
  • Dex can act as a simple, local authentication provider for creating test users when evaluating Kubeflow.
  • Add users by editing the Dex ConfigMap at data.config.yaml.staticPasswords with email, username, quoted userID, and a bcrypt hash (or hashFromEnv).
  • Restart the Dex deployment to apply changes.
  • Mapping users to Kubeflow profiles (namespaces) is a separate configuration step inside Kubeflow.
Links and references

Watch Video