Setting username via OAuth on shared servers

未关闭
#9,540 2 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 2 天内回复

@excalq 已经在做这个了。

开始于 2026年1月16日。

评估

这个 Issue 还没有评估数据。

描述

Feature

We have a use case of providing users with pre-configured database connections, which shared servers works well for. However, each user has a separate account in these databases, matching the email in their OAuth authentication flow (via Auth0). Their passwords are sourced externally (aws rds generate-db-auth-token) and short-lived, so we only need to set usernames, not passwords.

I was attempting to set a configuration to achieve this using servers.json, but it does not appear possible, looking at the codebase. We don't want a shared username, nor does Username: null cause the email/oauth-username-claim to be used, instead username is missing, and 'must be specified'.

The goal: Use the value of OAUTH2_USERNAME_CLAIM for Shared Servers instead of SharedUsername.

Related Issue: Shared Usernames: #6229

Describe alternatives you've considered

  1. Provisioning non-shared databases, per user: The servers.json is loaded into the SQLite DB once, as I understand, and removing it has undesired consequences, so this would be burdensome when adding new users.

Additional context

I am willing to contribute a PR with some changes in ‎ServerModule.create_shared_server, but would like to open this discussion first.

主要语言
Python
星标
3.9k
派生
922
平均合并
2 天 3 小时
30 天内合并 PR
33

环境准备

  • 提供 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

pgadmin-org/pgadmin4 的其他 Issue

查看 pgadmin-org/pgadmin4 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。