1
0
mirror of https://github.com/ansible/awx.git synced 2024-10-31 23:51:09 +03:00
awx/Makefile

97 lines
2.3 KiB
Makefile
Raw Normal View History

release = ansibleworks-1.2b1
2013-03-13 21:09:36 +04:00
clean:
rm -rf build *.egg-info
2013-03-13 21:09:36 +04:00
find . -type f -regex ".*\.py[co]$$" -delete
2013-03-13 23:28:30 +04:00
rebase:
git pull --rebase origin master
push:
git push
2013-03-13 23:15:35 +04:00
zero:
# go back to original database state, be careful!
2013-03-13 23:21:06 +04:00
python manage.py migrate main zero
2013-03-13 23:15:35 +04:00
2013-03-01 04:52:14 +04:00
setup:
# use ansible to ansible ansible commander locally
2013-03-13 23:15:35 +04:00
ansible-playbook app_setup/setup.yml --verbose -i "127.0.0.1," -c local -e working_dir=`pwd`
2013-03-01 04:52:14 +04:00
develop:
# "Install" ansibleworks package in development mode. Creates link to
# working copy in site-packages,
python setup.py develop
refresh: clean develop syncdb migrate
# update/refresh development environment after pulling new code
adduser:
python manage.py createsuperuser
2013-03-01 04:52:14 +04:00
syncdb:
2013-03-13 23:15:35 +04:00
# only run from initial setup
python manage.py syncdb --noinput
2013-03-01 04:52:14 +04:00
runserver:
2013-03-13 23:15:35 +04:00
# run for testing the server
2013-03-13 23:21:06 +04:00
python manage.py runserver
2013-03-01 04:52:14 +04:00
celeryd:
# run to start the background celery worker
python manage.py celeryd -l DEBUG -B --autoreload
2013-03-01 04:52:14 +04:00
# already done and should not have to happen again:
#
#south_init:
# python manage.py schemamigration main --initial
2013-03-01 04:52:14 +04:00
dbchange:
2013-03-13 23:15:35 +04:00
# run this each time we make changes to the model
2013-03-14 00:29:51 +04:00
python manage.py schemamigration main changes --auto
2013-03-01 04:52:14 +04:00
migrate: syncdb
# This command fixes migrations following the cleanup for the 1.2b1 release.
2013-05-25 02:12:20 +04:00
-(python manage.py migrate main 2>&1 | grep 0017_changes) && (python manage.py migrate main --delete-ghost-migrations --fake 0001_v12b1_initial || python manage.py migrate main --fake)
2013-03-13 23:15:35 +04:00
# run this to apply changes to the model
python manage.py migrate --noinput
2013-03-13 23:15:35 +04:00
dbshell:
# access database shell
# asks for password # PYTHON_PATH=./acom python acom/manage.py dbshell
sudo -u postgres psql -d acom
2013-03-01 04:52:14 +04:00
test:
2013-03-13 23:21:06 +04:00
python manage.py test main
test_coverage:
# Run tests with coverage enabled.
coverage run manage.py test main
coverage_html:
# Output test coverage as HTML (into htmlcov directory).
coverage html
dev_build:
python setup.py dev_build
release_build:
python setup.py release_build
release_ball: clean
make release_build
(cd ../ansible-doc; make)
-(rm -rf $(release))
mkdir -p $(release)/dist
cp -a dist/* $(release)/dist
mkdir -p $(release)/setup
cp -a setup/* $(release)/setup
mkdir -p $(release)/docs
cp -a ../ansible-doc/*.pdf $(release)/docs
tar -cvf $(release)-all.tar $(release)
clean:
-(rm *.tar)
-(rm -rf ($release))