Remove the committed connection string default and load secrets from Key Vault
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 45/100
调研方向
从 LearnStack/appsettings.json:2-4 和 LearnStack/Program.cs:32-33 开始,跟踪当前如何加载和验证连接字符串。然后检查使用 Key Vault 或 managed identity 的生产配置路径。完成标准是源代码管理中不再保留连接字符串,生产环境使用 managed identity,并且不完整的配置会产生明确的启动错误。
由索引模型根据 Issue 内容生成。
描述
Tier 2 — configuration
Problem
appsettings.json ships a LocalDB connection string as the default. In production this is dead weight at best; at worst, if the environment variable is missing, the app starts and tries to reach a database that does not exist rather than failing loudly with a clear message.
Evidence
LearnStack/appsettings.json:2-4LearnStack/Program.cs:32-33— throws only when the value is entirely absent
Proposed fix
- Remove the default from
appsettings.json; keep it inappsettings.Development.jsonor user secrets only. - Source the production connection string from Key Vault via managed identity, or use a passwordless Azure SQL connection with managed identity.
- Fail fast at startup with an actionable message when configuration is incomplete.
Acceptance criteria
- No connection string in source control
- Production connects with managed identity
- Missing configuration produces a clear startup error
- 主要语言
- HTML
- 星标
- 10
- 派生
- 0
- 平均合并
- 2 小时 35 分钟
- 30 天内合并 PR
- 21
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
kasuken/LearnStack 的其他 Issue
-
enhancement
难度 1/5 1 小时以内 新手友好度 91/100
kasuken/LearnStack#59 ·
维护者通常 1 天内回复
-
enhancement
难度 5/5 一周以上 新手友好度 35/100
kasuken/LearnStack#72 ·
维护者通常 1 天内回复
-
enhancement
难度 5/5 一周以上 新手友好度 30/100
kasuken/LearnStack#71 ·
维护者通常 1 天内回复
-
enhancement
难度 5/5 一周以上 新手友好度 35/100
kasuken/LearnStack#70 ·
维护者通常 1 天内回复
-
enhancement
难度 5/5 一周以上 新手友好度 45/100
kasuken/LearnStack#69 ·
维护者通常 1 天内回复
查看 kasuken/LearnStack 的全部 Issue
相似的 Issue
-
api: run samples
难度 2/5 1-3 小时 新手友好度 62/100
GoogleCloudPlatform/python-docs-samples#14633 ·
维护者通常 5 天内回复
-
难度 2/5 1-3 小时 新手友好度 70/100
apache/iceberg-python#4093 ·
维护者通常 1 天内回复
-
enhancement exporter/awss3 needs triage
难度 2/5 1-3 小时 新手友好度 66/100
open-telemetry/opentelemetry-collector-contrib#51905 · 1 条评论 ·
维护者通常 1 天内回复
-
- P2: has workaround pkg: cloudflare triage: fix pending
难度 2/5 1-3 小时 新手友好度 65/100
withastro/astro#18319 · 1 条评论 ·
维护者通常 1 天内回复
-
@aws-cdk/aws-lambda needs-triage
难度 2/5 1-3 小时 新手友好度 65/100
维护者通常 1 天内回复