docker compose

#1
by pvanand - opened

Hey @ds460, thank you for creating this space. It would be helpful if you can answer the following questions
You have defined a docker compose file. Is it actually used by hugging face spaces? I wanted to use docker compose to host multiple streamlit apps, is it possible?
ex docker-compose.yml (not sure if this works)

version: '3.9'

services:
  streamlit1:
    build:
      dockerfile: Dockerfile
      context: ./app1
    container_name: streamlit-app1
    cpus: 2
    mem_limit: 2048m
    ports:
      - "8501:8501"
    volumes:
      - "./app1:/app:rw"

  streamlit2:
    build:
      dockerfile: Dockerfile
      context: ./app2
    container_name: streamlit-app2
    cpus: 2
    mem_limit: 2048m
    ports:
      - "8502:8501"
    volumes:
      - "./app2:/app:rw"

related discussion:
https://discuss.huggingface.co/t/support-for-docker-compose-in-spaces/41512

Big Data Programming org

Yes it is. It is the default Hugging Face docker space with my default streamlit apps.

Thanks, but I tried changing the docker-comopse.yml from your duplicated space, and it seems unaffected. Looks like it is not supported
https://huggingface.co/spaces/pvanand/template_streamlit_docker/tree/main

Big Data Programming org

Oh could be. Been using docker compose locally. Sorry. The single streamlit apps do build.

Sign up or log in to comment