0.2, update to chainguard
Build and Publish Docker Image / Build and Push Docker Image (push) Successful in 7m23s
Details
Build and Publish Docker Image / Build and Push Docker Image (push) Successful in 7m23s
Details
This commit is contained in:
parent
25696c5ccc
commit
775e90df1c
10
Dockerfile
10
Dockerfile
|
|
@ -7,7 +7,8 @@ COPY frontend/ ./
|
|||
RUN npm run build
|
||||
|
||||
# Stage 2: Build Python virtual environment
|
||||
FROM python:3.11-slim AS python-builder
|
||||
FROM cgr.dev/chainguard/python:latest-dev AS python-builder
|
||||
USER root
|
||||
WORKDIR /build
|
||||
RUN python -m venv /opt/venv
|
||||
ENV PATH="/opt/venv/bin:$PATH"
|
||||
|
|
@ -16,7 +17,8 @@ COPY app/ ./app/
|
|||
RUN pip install --no-cache-dir --upgrade pip && pip install --no-cache-dir .
|
||||
|
||||
# Stage 3: Production Runtime
|
||||
FROM python:3.11-slim AS runtime
|
||||
FROM cgr.dev/chainguard/python:latest-dev AS runtime
|
||||
USER root
|
||||
WORKDIR /app
|
||||
|
||||
ENV PYTHONDONTWRITEBYTECODE=1 \
|
||||
|
|
@ -24,8 +26,8 @@ ENV PYTHONDONTWRITEBYTECODE=1 \
|
|||
PATH="/opt/venv/bin:$PATH" \
|
||||
PORT=8000
|
||||
|
||||
RUN groupadd --gid 1001 appgroup && \
|
||||
useradd --uid 1001 --gid appgroup --create-home appuser && \
|
||||
RUN addgroup -g 1001 appgroup && \
|
||||
adduser -D -u 1001 -G appgroup appuser && \
|
||||
mkdir -p /data && chown -R appuser:appgroup /app /data
|
||||
|
||||
COPY --from=python-builder /opt/venv /opt/venv
|
||||
|
|
|
|||
|
|
@ -1,2 +1,2 @@
|
|||
[version]
|
||||
version = 0.1
|
||||
version = 0.2
|
||||
|
|
|
|||
Loading…
Reference in New Issue