一覧へ戻る
A working example of nginx+flask+postgres multi-container setup using Docker Compose
- star 数
- 130
- watcher 数
- 4
- fork 数
- 54
- issue 数
- 1
- 最終更新
- 2017/09/28
A working example of nginx+flask+postgres multi-container setup using Docker Compose
This is a working example of a multi-container flask application with Postgres as the database fronted by the nginx reverse proxy. See my blog post for a detailed explanation.
$ docker-compose up -d db
$ docker-compose run --rm flaskapp /bin/bash -c "cd /opt/services/flaskapp/src && python -c 'import database; database.init_db()'"$ docker-compose up -d