Collaboration Support Bot supporting my team.
Find a file
Joseph McQueen 59460b849b Fix DECT relay container: install node_modules at /workspace, not under agent
The runtime container failed with ERR_MODULE_NOT_FOUND: axios when
integrations/cisco-dect/client.js tried to load. Root cause is
Node's ESM resolver: it walks UP from the IMPORTING file looking
for node_modules, never sideways into siblings.

Container filesystem before:
  /workspace/dect-relay-agent/node_modules/       <- axios lives here
  /workspace/dect-relay-agent/index.js            <- ok, finds it by walking up
  /workspace/integrations/cisco-dect/client.js    <- walks up to /, never sees axios

Node 20.20 has --experimental-detect-module ON by default, so
client.js is still treated as ESM (starts with `import`), and the
resolver correctly reports "cannot find package 'axios'" rather
than syntax-erroring on the import keyword. But it still can't find
the package — the location is wrong.

Fix: install node_modules at /workspace/ so BOTH the agent AND the
shared modules can find it by walking up.

  /workspace/node_modules/                        <- axios here now
  /workspace/package.json                         <- also here, "type":"module" for all descendants
  /workspace/dect-relay-agent/index.js            <- walks up to /workspace/node_modules ✓
  /workspace/integrations/cisco-dect/client.js    <- walks up to /workspace/node_modules ✓
  /workspace/utils/httpDigestAuth.js              <- same ✓

WORKDIR moves from /workspace/dect-relay-agent to /workspace, and
CMD changes accordingly:
  node --enable-source-maps dect-relay-agent/index.js

Rebuild + reship the bundle with `./dect-relay-agent/bundle.sh` and
`./install.sh` on the DC host — it's an idempotent upgrade.

Verified locally (agent modules import cleanly using the same
directory shape as the container).
2026-07-03 10:15:57 -04:00
commands DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
config Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
dect-relay-agent Fix DECT relay container: install node_modules at /workspace, not under agent 2026-07-03 10:15:57 -04:00
integrations Add DBS-210 status.xml parser + health verdict 2026-07-02 15:35:34 -04:00
public Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
services DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
tests DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
utils Add Cisco DBS-210 DECT base spike (HTTP Digest client + safe probes) 2026-07-02 15:30:42 -04:00
.dockerignore Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
.env.example DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
.gitignore Rework DECT relay bundle to ship a pre-built Docker image 2026-07-03 10:05:05 -04:00
docker-compose.yml Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
Dockerfile Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
index.js DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
nodemon.json Initial commit: CollabFinder Webex bot 2026-07-01 16:55:03 -04:00
package-lock.json DECT relay Phase 1: WSS hub + agent + /phonestatus follow-up 2026-07-02 17:03:32 -04:00
package.json Rework DECT relay bundle to ship a pre-built Docker image 2026-07-03 10:05:05 -04:00