Spaces:
Sleeping
Sleeping
| # BORION φ⁴³ Hyperspectral Compression Pipeline | |
| # Multi-stage production build - 78% L3 compression verified | |
| FROM python:3.11-slim AS base | |
| # Metadata | |
| LABEL maintainer="AQARION / BORION Team" | |
| LABEL version="1.0" | |
| LABEL description="BORION φ⁴³ L3 78% hyperspectral compression pipeline" | |
| LABEL φ⁴³="22.93606797749979" | |
| # Install system dependencies (minimal) | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| curl \ | |
| wget \ | |
| git \ | |
| h5py \ | |
| build-essential \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Create non-root user | |
| RUN useradd --create-home --shell /bin/bash borion \ | |
| && mkdir -p /app/datasets /app/logs /app/python \ | |
| && chown -R borion:borion /app | |
| # Switch to non-root user | |
| USER borion | |
| WORKDIR /app | |
| # Copy production pipeline | |
| COPY --chown=borion:borion PYTHON/*.py python/ | |
| COPY --chown=borion:borion FEB7TH-FLOW.MD ./ | |
| # Install Python dependencies (production optimized) | |
| COPY --chown=borion:borion requirements.txt . | |
| RUN pip install --no-cache-dir --user -r requirements.txt | |
| # Environment variables | |
| ENV PHI43=22.93606797749979 \ | |
| DATA_DIR=/app/datasets \ | |
| OUTPUT_DIR=/app/logs \ | |
| PYTHONPATH=/app/python \ | |
| PORT=7864 \ | |
| HOST=0.0.0.0 | |
| # Healthcheck | |
| HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \ | |
| CMD curl -f http://localhost:${PORT}/status || exit 1 | |
| # Expose production port | |
| EXPOSE ${PORT} | |
| # Volume mounts for datasets/logs | |
| VOLUME ["/app/datasets", "/app/logs"] | |
| # Production startup | |
| COPY --chown=borion:borion docker-entrypoint.sh . | |
| RUN chmod +x docker-entrypoint.sh | |
| ENTRYPOINT ["./docker-entrypoint.sh"] | |
| # Default command: run full L3 verification | |
| CMD ["--verify-all"] |