- Use as template.
- Modify
postBuildto point to your app. - Modify
Dockerfileif needed.
This project was set up to work with both mybinder.org and a local docker build which will launch streamlit by default.
To use it, run
docker build -t streamlit-demo .
docker run --rm -ti --name demo-env -p 8501:8501 streamlit-demoor using docker-compose.yml:
version: "3"
services:
demo:
container_name: demo-env
image: streamlit-demo
build:
dockerfile: Dockerfile
context: .
ports:
- "8501:8501"
command: streamlit run app.py --server.address 0.0.0.0 --server.port 8501 --server.enableCORS False --server.enableXsrfProtection FalseTo ensure future reproducibility, it is advised to pin the requirements in postBuild and requirements.txt to exact package versions.
The core dependencies to function with binder.org evolve (slowly) over time, and so they have been left unpinned here.