Skip to content

Latest commit

 

History

History
42 lines (23 loc) · 1.17 KB

README.md

File metadata and controls

42 lines (23 loc) · 1.17 KB

Dockerized Thought-App with Django and PostgreSQL

Development

Uses the default Django development server.

  1. .env.dev Configuration settings for Development(Debug on, localhost)

  2. docker-compose.yml docker file for development(mounted app volume)

  3. Build the images and run the containers:

    $ docker-compose up -d --build

    Test it out at http://localhost:8000. The "app" folder is mounted into the container and your code changes apply automatically.

Production

Uses gunicorn + nginx.

  1. .env.prod and .env.prod.db are Production configuration files for Docker and Database settings

  2. Build the images and run the containers:

    $ docker-compose -f docker-compose.prod.yml up -d --build

    Test it out at http://localhost:1337. No mounted folders.

Loading Fixtures

Example on loading users fixtures from Django manage.py of the running container web-app

$ docker-compose -f docker-compose.prod.yml exec web python manage.py loaddata fixtures/users.json

Future Work

Adding Machine Learning(ML) sklearn docker support by changing Alpine base image