File size: 590 Bytes
96ef23c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
FROM python:3.11-slim

ENV PYTHONUNBUFFERED=1
ENV PORT=7860
ENV KEY_FARM_ROOT=/data/farm
ENV KEY_FARM_FORMATION=cpu-worker
ENV MESHSCALE_FULL_KEY_REQUIREMENTS=1

WORKDIR /app
COPY . /app

RUN python -m pip install --upgrade pip \
    && python -m pip install --no-cache-dir -r meshscale_worker_space/requirements.txt \
    && if [ "$MESHSCALE_FULL_KEY_REQUIREMENTS" = "1" ] && [ -f requirements.txt ]; then \
        python -m pip install --no-cache-dir -r requirements.txt; \
    fi

CMD ["python", "-m", "uvicorn", "meshscale_worker_space.app:app", "--host", "0.0.0.0", "--port", "7860"]