Giter Club home page Giter Club logo

cord's Introduction

CORD

##Host management of docker containers and networking based on node-red

##Installation Steps ###Ubuntu ####Install Latest Docker

sudo curl -sSL https://experimental.docker.com/ | sh

####Install Latest Node

sudo apt-get install curl
sudo curl -sL https://deb.nodesource.com/setup_0.12 | sudo bash -

####Install Node-red

sudo npm install -g node-red

####Install mongodb

sudo apt-get install mongodb

####Install pipework

sudo git clone https://github.com/jpetazzo/pipework.git
sudo cp pipework /usr/bin/.
sudo chmod 755 /usr/bin/pipework

####Install prerequisite nodes and CORD nodes

cd $NODE_RED_NODE_DIR
Most likely /usr/lib/node_modules/node-red/nodes/
sudo npm install node-red-contrib-mongodb2
sudo npm install dockerode
sudo git clone https://github.com/donNewtonAlpha/CORD.git

####ADD lan network interfaces

sudo bash
for i in `seq 2 12`
   do 
   ip link add link $LAN_INTERFACE $LAN_INTERFACE.$i type vlan proto 802.1ad id $i
   ip link set $LAN_INTERFACE.$i up
   for j in `seq 2 100`
      do 
      ip link add link $LAN_INTERFACE.$i $LAN_INTERFACE.$i.$j type vlan proto 802.1q id $j
      ip link set $LAN_INTERFACE.$i.$j up
   done
done
exit

#####ADD wan interface

sudo bash
ip link add link $WAN_INTERFACE $WAN_INTERFACE.0 type vlan proto 802.1q id 0
ip link set $WAN_INTERFACE up
exit

####Start Node-red and reset flow file

sudo nohup node-red 2>&1 &

#ensure flow-file create
ls $HOME/.node-red/flows_$HOSTNAME.json
rm $HOME/.node-red/flows_$HOSTNAME.json
#sym link application.js
ln -s /usr/lib/node_modules/node-red/nodes/CORD/application.js $HOME/.node-red/flows_$HOSTNAME.json
#restart
sudo nohup node-red 2>&1 &

in webbrowser open http://$NODE_RED_IP:1880 and verify application is loaded

cord's People

Contributors

donnewtonalpha avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.