def test_build_python_app_package(): build_dir = mkdtemp() make.python_app_package('app-packr', 'origin/master', 'git://github.com/oremj/app-packr.git', build_dir) assert os.path.isdir(os.path.join(build_dir, 'app-packr', '.git')) assert os.path.isfile(os.path.join(build_dir, 'venv', 'bin', 'python')) rmtree(build_dir)
def build_release(ref, build_id, build_dir): """Build release. This assumes puppet has placed settings in /settings""" make.python_app_package('solitude', version=ref, repo='git://github.com/mozilla/solitude.git', requirements='requirements/prod.txt', build_dir=build_dir) local('rsync -av %s/aeskeys/ %s/aeskeys/' % (PROJECT_DIR, build_dir)) local('rsync -av %s/settings/ %s/solitude/solitude/settings/' % (PROJECT_DIR, build_dir)) with lcd(os.path.join(build_dir, 'solitude')): local('git log --oneline -1 > %s' % os.path.join(build_dir, 'REVISION'))
def build(ref, build_id, build_dir): make.python_app_package('monolith-aggregator', version=ref, repo='git://github.com/mozilla/monolith-aggregator.git', requirements='requirements/prod.txt', build_dir=build_dir) with lcd(os.path.join(build_dir, 'monolith-aggregator')): local('../venv/bin/python setup.py develop') with lcd(build_dir): local('./venv/bin/virtualenv --relocatable ./venv') local('rsync -av %s/ %s/' % ( os.path.join(fabconfig.PROJECT_DIR, 'settings'), os.path.join(build_dir, 'configs')))