Home
Softono

Docker Dash Example

Open source Python
22
Stars
11
Forks
0
Issues
2
Watchers
3 years
Last Commit

 About Docker Dash Example

Example of containerized deployment of Dash app to Google Cloud Run, https://docker-dash-example.com/

Platforms

Web Self-hosted Cloud Docker

Languages

Python

Links

Need Help Installing Docker Dash Example?

We provide expert installation service for this software. Our team will install, configure, and secure Docker Dash Example on your server. plans start at just $30.

Docker Dash Example

View on GitHub
  • Note: hotfix for werkzeug issue #1992 in place
  • Note: changed deployment from Heroku to Google Cloud Run

Docker Dash Example

A simple design for a plotly-dash app with sklearn running within a docker container deployed to Google Cloud Run using CI/CD. Continuous Integration and Delivery

For a deep dive on the implementation please see:

  1. Initial deployment through Heroku.
  2. Current deployment to GCP through Google Cloud Run

Inspired by This TDD Course

Using pre-commit-hooks

Repo structure

├── .github
│   └── workflows
│        └── main.yml
│
├── project
│   ├── app
│   │   ├── __init__.py
│   │   ├── app.py
│   │   ├── functions.py
│   │   └── assets
│   ├── tests
│   │   └── test_functions.py
│   ├── Dockerfile
│   ├── Dockerfile.prod
│   └── requirements.txt
│
├── release.sh
├── setup.cfg
├── .pre-commit-config.yaml
├── .gitignore
│
└── README.md

Run locally

To run the image locally, cd into the docker-dash-example folder and:

docker build -t docker-dash project/.

And run the container

docker run -p 8050:8050 docker-dash

You can find to the app on your local machine http://localhost:8050/ (or localhost:8050). This way the image is created using the Dockerfile, instead of the Dockerfile.prod.

Project context

This was a fun project to apply different learnings in practice, very happy to hear your thoughts in the repo, including feedback of course!