Spaces:
Running
Running
| FROM python:3.11-slim | |
| WORKDIR /app | |
| # Install dependencies | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy SignalMesh source | |
| COPY core/ core/ | |
| COPY agents/ agents/ | |
| COPY workspace/ workspace/ | |
| COPY tools/ tools/ | |
| COPY signalmesh_api.py . | |
| # HuggingFace Spaces runs as non-root — ensure workspace is writable | |
| RUN chmod -R 777 workspace/ | |
| # Expose the API port | |
| EXPOSE 7860 | |
| # HF Spaces injects PORT env var; fall back to 7860 | |
| CMD ["sh", "-c", "uvicorn signalmesh_api:app --host 0.0.0.0 --port ${PORT:-7860}"] | |