If you know YAML, you know Pakefiles. Also it’s good to know a little about make.
default:
target: build
target: bundle
build:
shell:
sudo python setup.py install
bundle:
python:
import myapp
myapp.db.test()
myapp.db.flush()
shell:
tar -cjf bundle.tar myapp/
deploy:
target: default
shell:
fab deploy
P.S. fab is a deployment tool. Like this, but for other tasks.