Skip to content

Instantly share code, notes, and snippets.

@philippeowagner
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save philippeowagner/bc2cd1b685c49a35810f to your computer and use it in GitHub Desktop.
Save philippeowagner/bc2cd1b685c49a35810f to your computer and use it in GitHub Desktop.
Install the 3bot worker an your machine
[3bot-settings]
BOT_ENDPOINT=*
PORT = 55556
SECRET_KEY = ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789
#!/bin/sh
{
echo "This script requires superuser access to install software."
echo "You will be prompted for your password by sudo."
# clear any previous sudo permission
sudo -k
# run inside sudo
sudo sh <<SCRIPT
mkdir -p /usr/local/3bot/
virtualenv --no-site-packages /usr/local/3bot/
cd /usr/local/3bot/
. ./bin/activate
pip install -e git+ssh://git@bitbucket.org/arteria/3bot-worker#egg=threebot_worker
mkdir -p /etc/3bot/
wget curl https://gist.githubusercontent.com/philippeowagner/bc2cd1b685c49a35810f/raw/config.ini -O /etc/3bot/config.ini
echo "/usr/local/3bot/src/threebot-worker/threebot_worker/worker.py start"
SCRIPT
echo "Installation complete"
}
@philippeowagner
Copy link
Author

USE ON YOUR OWN RISK!

Install a 3bot worker using this script. On your command line / terminal run

curl https://gist.githubusercontent.com/philippeowagner/bc2cd1b685c49a35810f/raw/install.sh|sh

Please note that virtualenv and pip must be installed on your Debian, Ubuntu or Mac. Other systems are currently not tested.

Do not forget to change the SECRET_KEY.

After installation is completed, start the worker using this command.

cd /usr/local/3bot/
. ./bin/activate 
/usr/local/3bot/src/threebot-worker/threebot_worker/worker.py start

To run the worker in the foreground (no ) just pass call the worker with start debug instead of start.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment