Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- export ROOT_URL=http://localhost
- export PORT=11014
- export MONGO_URL=mongodb://localhost:27017/lair
- export MONGO_OPLOG_URL=mongodb://localhost:27017/local
- export API_LISTENER=localhost:11015
- export NVM_DIR="$HOME/.nvm"
- [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
- ./mongodb-linux-x86_64-3.2.1/bin/mongod --dbpath=db --bind_ip=localhost --quiet --nounixsocket --replSet rs0 &
- MONGOPROCESS=$!
- sleep 3
- cd bundle; nvm use v6.9.1; node main.js &
- cd ../; ./api-server_linux_amd64 &
- APIPROCESS=$(ps aux | grep "\.\/api-server_linux_amd64" | grep -v "grep" | tr -s ' ' | cut -f 2 -d ' ')
- sleep 2
- ./caddy --conf=Caddyfile &
- CADDYPROCESS=$!
- trap "{ kill $MONGOPROCESS ; kill $CADDYPROCESS ; kill $APIPROCESS ; exit 1 }" SIGINT SIGTERM EXIT
- read towait
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement