headlamp-k8s / headlamp

A Kubernetes web UI that is fully-featured, user-friendly and extensible
https://headlamp.dev
Apache License 2.0
2.22k stars 156 forks source link

Auto logout after 5 minutes of inactivity via keycloak login. #1101

Closed jgyy closed 9 months ago

jgyy commented 1 year ago

I kept receiving these stream of error in console log whenever I login to headlamp via keycloak OIDC, it happens when I am inactive from the webapp for 5 minutes. console logs shown below. Is there a workaround to increase inactivity session duration? I am hosting this headlamp in cluster and it is very inconvenient to keep logging back in so frequently. Thank You!

apiProxy.ts:773  Socket closed unexpectedly {path: 'api/v1/persistentvolumes?watch=1&resourceVersion=163140949', args: Array(1)}
g @ apiProxy.ts:773
apiProxy.ts:693 Reconnecting in 3 seconds {url: 'api/v1/persistentvolumes?watch=1&resourceVersion=163140949'}
apiProxy.ts:736  WebSocket connection to 'wss://headlamp.sandbox.k8ns.in/clusters/main/api/v1/events?watch=1&resourceVersion=163140949' failed: 
(anonymous) @ apiProxy.ts:736
d @ apiProxy.ts:686
apiProxy.ts:778  Error in api stream {err: Event, path: 'api/v1/events?watch=1&resourceVersion=163140949'}
knrt10 commented 9 months ago

Fixed via https://github.com/headlamp-k8s/headlamp/pull/1636