Sign inSign up

cloudgear10/cloudgear

By cloudgear10

•Updated almost 11 years ago

node-red with freeboard and web sockets

Image
1

949

cloudgear10/cloudgear repository overview

pull and run this via:

sudo docker run -d -p 1880:1880 -p 1881:1881 cloudgear10/cloudgear

Node-red: http://:1880 Freeboard: http://:1880/freeboard

  1. node-red pulled from git and started on 1880.

  2. It also has a freeboard running on same port.

  3. Freeboard has websocket enabled.

  4. It has dashing gem installed too and with exposed port of 1881.

  5. dashing can be started by getting in the started container sudo docker exec -ti <containerid> "bash"

    cd /opt/cloudgear && dashing start -p 1881 -d

  6. The sample dashing would be running at http://:1881/sample

P.S: Will Iteratively reduce Size...

⁠Dockerfile
FROM fedora
MAINTAINER cloudgear10 <[email protected]>

RUN dnf -y update && dnf clean all
RUN dnf install python  make git -y
RUN dnf install wget unzip vim -y
RUN dnf install -y nodejs npm
RUN npm install -g grunt-cli
RUN dnf install gcc ruby-devel rubygems -y
RUN gem install dashing
RUN gem install bundler
RUN cd /opt && dashing new cloudgear
RUN cd /opt/cloudgear && bundle
#RUN cd /opt/cloudgear && dashing start -p 1881 -d
RUN cd /opt && git clone https://github.com/node-red/node-red.git
RUN cd /opt/node-red && npm install
RUN cd /opt/node-red && grunt build
EXPOSE 1880
EXPOSE 1881
RUN cd /opt/node-red && npm install node-red-contrib-freeboard
RUN cd /opt/node-red/node_modules/node-red-contrib-freeboard/node_modules/freeboard/plugins/ && git clone https://github.com/Freeboard/plugins.git
RUN cd /opt/node-red/node_modules/node-red-contrib-freeboard/node_modules/freeboard/plugins/plugins && mv * ../
RUN cd /opt/node-red/node_modules/node-red-contrib-freeboard/node_modules/freeboard/plugins/ && rm -rf plugins
RUN cd /opt/node-red/node_modules/node-red-contrib-freeboard/node_modules/freeboard/ && sed -i.bak -e '13d' index.html
RUN cd /opt/node-red/node_modules/node-red-contrib-freeboard/node_modules/freeboard/ && sed -i '13ihead.js("js/freeboard.js","js/freeboard.plugins.min.js", "../freeboard_api/datasources","plugins/datasources/plugin_json_ws.js","plugins/datasources/plugin_node.js",' index.html
RUN cd /opt/cloudgear/
CMD ["node", "/opt/node-red/red.js"]
#CMD ["dashing", "-p 1881" "-d" "start"]

Tag summary

Content type

Image

Digest

sha256:f1b89d7ed…

Size

1 GB

Last updated

almost 11 years ago

docker pull cloudgear10/cloudgear