Last active
November 30, 2015 22:01
-
-
Save frapontillo/522aa54a2df9c741fe97 to your computer and use it in GitHub Desktop.
Crowd Pulse Install Scripts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # install build tools and node for ubuntu | |
| sudo apt-get update -y | |
| sudo apt-get install -y build-essential | |
| curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash - | |
| sudo apt-get install -y nodejs | |
| cd /opt/ | |
| # download and install crowd-pulse | |
| wget https://github.com/frapontillo/crowd-pulse/archive/0.0.1.tar.gz -O crowd-pulse.tar.gz | |
| mkdir crowd-pulse/logs | |
| tar -xfvz crowd-pulse.tar.gz -C crowd-pulse --strip-components 1 | |
| rm crowd-pulse.tar.gz | |
| ./crowd-pulse/gradlew installDist -p crowd-pulse/ | |
| # you may want to chown the /usr/local/bin directory | |
| sudo chown -R $(whoami) /usr/local/bin | |
| # install the web service and the web ui | |
| npm install -g crowd-pulse-web-service crowd-pulse-web-ui | |
| # export variables for the web service | |
| echo 'export CROWD_PULSE_WS_PORT=5000' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_WS_MONGO_URL="localhost"' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_WS_MONGO_DB="admin"' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_MAIN_EXE="/opt/crowd-pulse/build/install/crowd-pulse/bin/crowd-pulse"' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_LOGS_PATH="/opt/crowd-pulse/logs"' >> ~/.bash_profile | |
| # export variables for the web ui | |
| echo 'export CROWD_PULSE_UI_API="http://193.204.187.192:5000/api/"' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_UI_SOCKET="http://193.204.187.192:5000/"' >> ~/.bash_profile | |
| echo 'export CROWD_PULSE_UI_INDEX="http://193.204.187.192:9000/rest/"' >> ~/.bash_profile | |
| # update shell | |
| source ~/.bash_profile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # launch web-service | |
| crowd-pulse-web-service > /opt/crowd-pulse/logs/web-service.log & | |
| # launch web-ui | |
| crowd-pulse-web-ui > /opt/crowd-pulse/logs/web-ui.log & |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| jobs | |
| kill -KILL %1 %2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment