FROM python:3.12-slim RUN useradd -m -u 1000 user RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/* # Install from PyPI (gets frontend static files + all deps) RUN pip install --no-cache-dir "embedding-atlas>=0.18.0" # Save static files before overwriting RUN cp -r $(python -c "import embedding_atlas, pathlib; print(pathlib.Path(embedding_atlas.__file__).parent / 'static')") /tmp/atlas-static # Overlay our branch code RUN pip install --no-cache-dir --force-reinstall --no-deps \ "embedding-atlas @ git+https://github.com/davanstrien/embedding-atlas.git@dataset-url-remote#subdirectory=packages/backend" # Restore static files RUN cp -r /tmp/atlas-static $(python -c "import embedding_atlas, pathlib; print(pathlib.Path(embedding_atlas.__file__).parent / 'static')") USER user EXPOSE 7860 CMD ["embedding-atlas", \ "--dataset-url", "https://huggingface.co/datasets/davanstrien/tinystories-atlas-data/resolve/main/dataset.parquet", \ "--text", "text", \ "--x", "projection_x", \ "--y", "projection_y", \ "--duckdb", "server", \ "--mcp", \ "--host", "0.0.0.0", \ "--port", "7860"]