Go to file
Joachim Lusiardi 5b69a82e05 adds tracking of costs
This commit adds a new field to each pitstop for tracking of
costs.
This includes:
* a new DB column
* a new field in the create pitstop form
* a new column in the pitstop overview
* new stats values related to costs
* 2 new graphs
2016-06-21 21:06:41 +02:00
app adds tracking of costs 2016-06-21 21:06:41 +02:00
.gitignore introduces modules 2016-04-23 23:08:39 +02:00
Dockerfile Users are allowed to register now 2016-04-19 07:39:17 +02:00
README.md adds tracking of costs 2016-06-21 21:06:41 +02:00
create_icons.sh introduces modules 2016-04-23 23:08:39 +02:00
icon_orig.png tuned apple icon 2015-03-22 11:02:59 +01:00

README.md

How to build & run

build

docker build --tag=$(basename $PWD) .

general configuration

Look at app/config/email.py.example* for the configuration of the parameters required for sending emails. Copy the file as email.py to a folder that will serve as configuration directory and fill in the information. The directory will be used as volume during container operation.

start database

docker run --name pitstops_db -e MYSQL_ROOT_PASSWORD=$SOMESECUREPASSWORD$ -e MYSQL_DATABASE=pitstops -d mysql:latest

Database migrations

From Cathrine to Master:

ALTER TABLE pitstop ADD COLUMN costs DECIMAL(5,2) NOT NULL DEFAULT 0.0 AFTER vehicle_id;

run in development

Include the development version of the code as volume, so the app gets reloaded automatically. The sqlite file will be stored in tmp so it can be inspected with tools like sqlite3. The switch DEBUG enables debugging during development.

docker run --rm --name rollerverbrauch -ti -v $PWD/app:/app -v $PWD/../rollerverbrauch_config:/app/config -v /tmp/pitstops/:/data -e DEBUG=True -e config=../config/config.py --link pitstops_db:database -p 5000:5000 rollerverbrauch

run in production

docker run --name pitstops -d -v /data/pitstops/:/data -v /configs/pitstops/:/app/config -p 80:5000 rollerverbrauch