Fix chain logout default rendering
General MR
Summary
Fixes per-chain logout config rendering so chain values inherit global.logout_path and global.logout_redirect_uri when unset.
Adds Helm unittests for:
- global logout defaults
- chain-local logout overrides
- OIDC logout URL fallback
Validated with helm unittest -f 'unittests/*_test.yaml' chart.
Note this MR skips the upgrade job as all installs are failing on main due to a loki+minio configuration mismatch, which is fixed by disabling loki in this MR's test-values.yaml.
Relevant logs/screenshots
k3d cluster verification:
Setup:
- Namespace:
authservice-logout-repro - Values used:
global: logout_path: /globallogout logout_redirect_uri: https://sso.example/logout chains: minimal: callback_uri: https://example.com/callback
Before, using origin/main 780790e:
{
"redirect_uri": "https://login.dso.mil/auth/realms/baby-yoda/protocol/openid-connect/token/logout"
}After, using fix-authservice-logout-defaults 6beb398:
{
"path": "/globallogout",
"redirect_uri": "https://sso.example/logout"
}Method was live API validation:
helm template ... --show-only templates/secret.yaml | kubectl apply -f -
kubectl -n authservice-logout-repro get secret authservice -o jsonpath='{.data.config\.json}' | base64 -d | jq ...Cleanup done:
namespace "authservice-logout-repro" deletedLinked Issue
Upgrade Notices
Per-chain logout configuration now inherits global logout defaults.
Previously, chains without logout_path or logout_redirect_uri did not inherit:
global:
logout_path: /globallogout
logout_redirect_uri: https://sso.example/logout
chains:
app:
callback_uri: https://app.example/callbackAfter this change, chains.app.filters[0].oidc_override.logout will render with:
{
"path": "/globallogout",
"redirect_uri": "https://sso.example/logout"
}If you need a different logout redirect for a chain, set it explicitly:
chains:
app:
callback_uri: https://app.example/callback
logout_redirect_uri: https://app.example/logoutIf you do not want a global logout path applied to chains, set global.logout_path: "" and configure logout_path only on chains that need it.