mirror of
https://github.com/BetterCorp/BetterFrame.git
synced 2026-05-26 20:16:35 +00:00
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.
19 lines
593 B
Docker
19 lines
593 B
Docker
# BetterFrame Node-RED image with bundled BF nodes preinstalled.
|
|
#
|
|
# Extends official nodered/node-red, installs the workspace nodered/
|
|
# package at /usr/src/betterframe-nodes. settings.js points nodesDir
|
|
# there so Node-RED scans it on boot. Survives /data volume mount.
|
|
|
|
FROM nodered/node-red:latest
|
|
|
|
USER root
|
|
|
|
# Copy our nodes into a path outside /data (which is volume-mounted)
|
|
COPY nodered /usr/src/betterframe-nodes
|
|
|
|
# Install deps for the nodes
|
|
RUN cd /usr/src/betterframe-nodes && \
|
|
npm install --omit=dev && \
|
|
chown -R node-red:root /usr/src/betterframe-nodes
|
|
|
|
USER node-red
|