Commit graph

4 commits

Author SHA1 Message Date
Mitchell R
7baa1a07f9
fix(nodered): seed /data/settings.js via entrypoint wrapper
The /data named volume hides anything Dockerfile COPYs into /data, so
the previous CMD override pointing at /usr/src/bf-settings.js didn't
help — Node-RED's launch script still looks for /data/settings.js by
default, which doesn't exist after the volume overlays.

Solution: entrypoint wrapper copies /usr/src/bf-settings.js to
/data/settings.js on first boot when missing, then exec's npm start.
Subsequent boots keep the user-edited version in the volume.
2026-05-19 03:57:42 +02:00
Mitchell R
c8fa5d95a2
fix(deploy): bake configs into images — no host bind mounts
Coolify deployments don't always carry the full source tree on disk
at the bind-mount source path. Mounting a missing file lets Docker
auto-create a directory at the target, which then fails to mount over
the file the image expects.

Fix: bake config files into the images themselves:
- Dockerfile.server COPYs deploy/docker/sec-config.yaml → /app/server/.
  Env vars (BF_*) still override at runtime per env-overrides.ts.
- New Dockerfile.angie wraps nginx:alpine + baked betterframe.docker.conf.
- Dockerfile.nodered COPYs nodered-settings.js to /usr/src/bf-settings.js
  (outside the /data volume) and uses --settings to point at it.

Compose drops the three bind mounts; volumes are now strictly
runtime state (DB + secrets, Node-RED flows). Users who want a
different sec-config still get full control via env overrides or
Coolify's Storage UI.
2026-05-18 12:18:46 +02:00
Mitchell R
44b0268def fix: nodered settings.js nodesDir → /usr/src/betterframe-nodes
Node-RED only scans userDir/node_modules by default. Setting
nodesDir explicitly tells it to also scan our baked-in path,
which survives the /data volume mount.
2026-05-13 02:00:40 +02:00
Mitchell R
896934ae84 feat: bake BF Node-RED nodes into nodered Docker image
- New deploy/docker/Dockerfile.nodered extends nodered/node-red,
  npm-installs the workspace nodered/ package into
  /usr/src/node-red/node_modules so bf-* nodes auto-load on boot.
- docker-compose nodered service switched from public image to
  this build context. Rebuilding (--build) picks up node changes.
2026-05-13 01:57:26 +02:00