headplane icon indicating copy to clipboard operation
headplane copied to clipboard

Cannot read properties of undefined

Open phil3741 opened this issue 1 year ago • 4 comments

Hello,

i recently tried to bump my headscale to 24.0 and headplane version from 0.3.9 to 0.4.1 and are now getting this error in the docker container:

2025-01-21T20:36:03.761Z (INFO) [SRVX] Using build directory /app/build
2025-01-21T20:36:06.676Z (INFO) [SRVX] Running Node.js 20.18.1
2025-01-21T20:36:06.715Z (INFO) [SRVX] Found dependencies
2025-01-21T20:36:06.727Z (INFO) [SRVX] Running on 0.0.0.0:3000
2025-01-21T20:36:06.832Z (INFO) [INTG] Loading integration: docker
2025-01-21T20:36:06.833Z (INFO) [INTG] Using container: headscale
2025-01-21T20:36:06.833Z (INFO) [INTG] Checking socket: /var/run/docker.sock
2025-01-21T20:36:06.834Z (INFO) [INTG] Loaded integration: docker
file:///app/build/server/index.js:967
  if (meta2.token_endpoint_auth_methods_supported.includes(oidc.tokenEndpointAuthMethod) === false) {
                                                  ^

TypeError: Cannot read properties of undefined (reading 'includes')
    at testOidc (file:///app/build/server/index.js:967:51)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async checkOidc (file:///app/build/server/index.js:1160:22)
    at async loadContext (file:///app/build/server/index.js:1074:11)

Node.js v20.18.1

I tried looking for an existing issue where I only found one reference about a OIDC_CLIENT_SECRET_METHOD: 'client_secret_post' which i added to the yaml, with no effect.

phil3741 avatar Jan 21 '25 20:01 phil3741

Looks like a bug, for now does setting OIDC_SKIP_CONFIG_VALIDATION=true fix the problem? This is simply a workaround and I don't recommend it, but the goal is to fix this in the next release.

tale avatar Jan 22 '25 13:01 tale

This indeed resolves the issue for now. Thank's for the quick answer!

phil3741 avatar Jan 23 '25 10:01 phil3741

I have the same problem, thanks for the workaround :)

patrikloveicyl avatar Jan 29 '25 14:01 patrikloveicyl

Fixed

tale avatar Feb 28 '25 18:02 tale