Skip to content

Instantly share code, notes, and snippets.

@skryv
skryv / gist:4709434
Created February 4, 2013 20:22
Update the configuration
supervisorctl update
@skryv
skryv / gist:4709415
Created February 4, 2013 20:19
Install & run supervisor
#Install supervisor in the pipy-local directory
cd /path/to/pipy-local
pip install supervisor
#create a standard configuration in this directory
echo_supervisord_conf > supervisord.conf
#run supervisor from this directory
supervisord
@skryv
skryv / gist:4709358
Last active December 12, 2015 03:48
Pypi server configuration for supervisord
[program:pypi-server]
command=pypi-server -p 8080 /path/to/pypi-local/packages
environment=PATH="/path/to/pypi-local/env/bin"
directory=/path/to/pypi-local
user=youruseraccount
autostart=true
autorestart=true
redirect_stderr=true
@skryv
skryv / gist:4708189
Created February 4, 2013 17:32
Run a local Pypi package server
# Create a local directory for the pypi server
mkdir pypi-local
cd pypi-local
# Make a separate virtual environment for the pypi server
virtualenv env
source env/bin/activate
#install the pypiserver
pip install pypiserver
mkdir ./packages
# copy some source packages or eggs to this directory
@skryv
skryv / gist:4653684
Created January 28, 2013 07:36
Adding the buildpack to your heroku app.
heroku config:add BUILDPACK_URL=https://github.com/ToonTimbermont/heroku-buildpack-python
@skryv
skryv / scikit-learn
Created January 28, 2013 07:15
Parameters required for skikit-learn installation
echo "-----> Installing via pip, but setting environment vars first."
export BLAS=$(pwd)/vendor/lib/atlas-base/atlas/libblas.a
export LAPACK=$(pwd)/vendor/lib/atlas-base/atlas/liblapack.a
export ATLAS=$(pwd)/vendor/lib/atlas-base/libatlas.a
export LIBRARY_PATH=$(pwd)/vendor/lib:$(pwd)/lib/atlas-base:$(pwd)/lib/atlas-base/atlas
export LD_LIBRARY_PATH=$(pwd)/vendor/lib:$(pwd)/vendor/lib/atlas-base:$(pwd)/vendor/lib/atlas-base/atlas
pip install --use-mirrors scikit-learn
@skryv
skryv / deploy.sh
Last active December 11, 2015 15:48
Deploying in two lines :)
git push heroku master #update the code
heroku run python manage.py migrate myapp #update the database of <myapp>