fix: Use NEXTCLOUD_OIDC_CLIENT_ID/SECRET env vars consistently
Fixes #296 The application code was looking for OIDC_CLIENT_ID and OIDC_CLIENT_SECRET (without NEXTCLOUD_ prefix), but the Helm chart, documentation, and CLI all use NEXTCLOUD_OIDC_CLIENT_ID and NEXTCLOUD_OIDC_CLIENT_SECRET. This mismatch caused OAuth deployments via Helm to fail with crashloops because the credentials weren't being found. Changes: - app.py: Use NEXTCLOUD_OIDC_CLIENT_ID/SECRET in setup_oauth_config() - config.py: Use NEXTCLOUD_OIDC_CLIENT_ID/SECRET in get_settings() - Updated documentation comments and error messages This aligns with the documented naming convention where all Nextcloud-related environment variables use the NEXTCLOUD_ prefix. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -288,8 +288,8 @@ def get_settings() -> Settings:
|
||||
return Settings(
|
||||
# OAuth/OIDC settings
|
||||
oidc_discovery_url=os.getenv("OIDC_DISCOVERY_URL"),
|
||||
oidc_client_id=os.getenv("OIDC_CLIENT_ID"),
|
||||
oidc_client_secret=os.getenv("OIDC_CLIENT_SECRET"),
|
||||
oidc_client_id=os.getenv("NEXTCLOUD_OIDC_CLIENT_ID"),
|
||||
oidc_client_secret=os.getenv("NEXTCLOUD_OIDC_CLIENT_SECRET"),
|
||||
oidc_issuer=os.getenv("OIDC_ISSUER"),
|
||||
# Nextcloud settings
|
||||
nextcloud_host=os.getenv("NEXTCLOUD_HOST"),
|
||||
|
||||
Reference in New Issue
Block a user