Files
OpenJarvis/deploy/docker/Dockerfile.gpu.rocm
T
e0dccd1b8d Update Dockerfile.gpu.rocm with ROCm 7.2 (#117)
* Update Dockerfile.gpu.rocm with ROCm 7.2

* fix: update ROCm 6.2 references in knowledge_base.py to 7.2

Matches the Dockerfile.gpu.rocm base image bump.

---------

Co-authored-by: robbym-dev <manihani@stanford.edu>
2026-04-03 22:01:00 -07:00

41 lines
1.0 KiB
Docker

# Stage 1: Build frontend SPA
FROM node:22-slim AS frontend
WORKDIR /frontend
COPY frontend/package.json frontend/package-lock.json* ./
RUN npm ci --ignore-scripts 2>/dev/null || npm install
COPY frontend/ .
RUN npm run build
# Stage 2: Build Python package (AMD ROCm 7.2)
FROM rocm/dev-ubuntu-22.04:7.2 AS builder
RUN apt-get update && \
apt-get install -y --no-install-recommends python3 python3-pip python3-venv && \
rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY pyproject.toml README.md ./
COPY src/ src/
COPY --from=frontend /src/openjarvis/server/static src/openjarvis/server/static/
RUN pip install --no-cache-dir uv && \
uv pip install --system ".[server]"
# Stage 3: Runtime
FROM rocm/dev-ubuntu-22.04:7.2
RUN apt-get update && \
apt-get install -y --no-install-recommends python3 python3-pip && \
rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local /usr/local
COPY --from=builder /app /app
WORKDIR /app
EXPOSE 8000
ENTRYPOINT ["jarvis"]
CMD ["serve", "--host", "0.0.0.0", "--port", "8000"]