Skip to content

rapid-sensemaking-framework/setup-guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 

Repository files navigation

setup-guide

This is how Robert set up a server from scratch on digital ocean

Services

Steps

a first step would be to git clone … those 4 repos

mkdir services
cd services
git clone https://github.com/rapid-sensemaking-framework/rsf-http-register.git
git clone https://github.com/rapid-sensemaking-framework/noflo-rapid-sensemaking-server.git
git clone https://github.com/rapid-sensemaking-framework/rsf-telegram-bot.git
git clone https://github.com/rapid-sensemaking-framework/rsf-twilio-bot.git


# install pm2
# will manage our processes
sudo npm install pm2@latest -g

# refer to this doc for use of systemd
# https://www.digitalocean.com/community/tutorials/how-to-set-up-a-node-js-application-for-production-on-ubuntu-18-04

# install the dependencies
cd rsf-http-register
npm install
# set up the environment variables
# add PORT=3000 to a new .env file
pm2 start --name rsf-http-register npm -- start
pm2 save
cd ..

# noflo-rapid-sensemaking-server
cd noflo-rapid-sensemaking-server
npm install


# modify env variables in script file `start`
nano start, or vi start
# PORT = 3001
# add to process manager
# startscript will run `start`
# set up TLS
# https://github.com/noflo/noflo-nodejs#securing-the-runtime-connection
pm2 start --name noflo-server npm -- run startscript
pm2 save
cd ..

# rsf-telegram-bot

# install mongodb dependency
sudo apt update
sudo apt install mongodb
sudo systemctl status mongodb
# log in to mongo shell
mongo
> use telegram # create db
> exit

cd rsf-telegram-bot
npm install

# create .env
touch .env
nano .env, or vim .env

# set the environment variables described here
# https://github.com/rapid-sensemaking-framework/rsf-telegram-bot/blob/master/README.md#environment-variables
# including PORT = 3002
pm2 start --name rsf-telegram-bot npm -- start
pm2 save
cd ..

# rsf-twilio-bot
cd rsf-twilio-bot
npm install
# create .env
touch .env
nano .env, or vim .env

# set the environment variables described here
# https://github.com/rapid-sensemaking-framework/rsf-twilio-bot/blob/master/README.md#environment-variables
# including PORT = 3003
pm2 start --name rsf-twilio-bot npm -- start
pm2 save


# opening up the ports
ufw allow 3000
ufw allow 3001
ufw allow 3002
ufw allow 3003

How To Set up a firewall with ufw With Digital Ocean: https://www.digitalocean.com/community/tutorials/how-to-set-up-a-firewall-with-ufw-on-ubuntu-18-04

graph TD;
    rsf-electron-->noflo-rapid-sensemaking-server;
    flowhub-->noflo-rapid-sensemaking-server;
    rsf-electron-->rsf-http-register;
    rsf-http-register-->web-Users;
    noflo-rapid-sensemaking-server-->noflo-rsf;
    noflo-rsf-->rsf-contactable;
    rsf-contactable-->rsf-telegramable;
    rsf-contactable-->rsf-smsable;
    rsf-contactable-->rsf-mattermostable;
    noflo-rsf-->rsf-http-register;
    rsf-smsable-->rsf-twilio-bot;
    rsf-telegramable-->rsf-telegram-bot;
    rsf-telegram-bot-->telegram-Users;
    rsf-twilio-bot-->cellphone-Users;
    rsf-mattermostable-->mattermost-Users;
Loading

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published