- python 2.7 only
- tox
- postgresql
- install dependencies:
./install_dependencies.sh
sudo pip install tox
tox -e base
- create base config:
cp ./config_template.py config.py
- migrations and run:
.tox/bin/python manage.py migrations
.tox/bin/python manage.py runserver
- image build:
docker build --tag=<image_name>:<image_version> .
-
create enviroment variables file or put environment variables in docker run command
-
run migrations:
docker run -it --rm --volume /var/run/docker.sock:/var/run/docker.sock --privileged --net=host <image_name>:<images_version> python manage.py migrations
- run container:
docker run -it --rm --volume /var/run/docker.sock:/var/run/docker.sock --privileged --net=host <image_name>:<images_version> python manage.py runserver
./install-hooks.sh
.tox/bin/flake8 vmmaster/ tests/
tox -e unit-with-coverage
Open coverage/index.html in web browser.
More information