Extract IDP configuration to external JSON file #1

Merged
administrator merged 1 commits from claude/update-set-up-logic into main 2026-03-22 11:26:31 +00:00
Owner

Summary

  • Move all hard-coded identity server settings (API resource, scope, client, users/roles) out of Program.cs into config/idp-config.json
  • Add JSON parsing logic at startup with a clear error message if the file is missing
  • Add support for multiple users with arbitrary roles, claims, and consents in the config file
  • Config file is copied to the build output directory for local development and lives at /app/config/idp-config.json in the Docker image

Docker usage

Override the config at runtime via a volume mount:

docker run ... -v /your/host/idp-config.json:/app/config/idp-config.json simpleidp

Test plan

  • Build and run locally — app starts using config/idp-config.json
  • Verify login works with the administrator user
  • Add a second user entry to the JSON and confirm it is accepted at login
  • Build Docker image and run with a mounted config file — confirm it overrides the default
## Summary - Move all hard-coded identity server settings (API resource, scope, client, users/roles) out of `Program.cs` into `config/idp-config.json` - Add JSON parsing logic at startup with a clear error message if the file is missing - Add support for multiple users with arbitrary roles, claims, and consents in the config file - Config file is copied to the build output directory for local development and lives at `/app/config/idp-config.json` in the Docker image ## Docker usage Override the config at runtime via a volume mount: ```bash docker run ... -v /your/host/idp-config.json:/app/config/idp-config.json simpleidp ``` ## Test plan - [ ] Build and run locally — app starts using `config/idp-config.json` - [ ] Verify login works with the `administrator` user - [ ] Add a second user entry to the JSON and confirm it is accepted at login - [ ] Build Docker image and run with a mounted config file — confirm it overrides the default
administrator added 1 commit 2026-03-22 11:24:16 +00:00
Move all hard-coded identity server settings (API resource, scope, client,
users/roles) from Program.cs into config/idp-config.json and add parsing
logic. The config file is copied to the output directory so it works for
local development and is available at /app/config/idp-config.json in the
Docker image, making it straightforward to override via a volume mount.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
administrator merged commit 4bbe881285 into main 2026-03-22 11:26:31 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: administrator/simpleidp#1