forked from claw/flaskpaste
containerfile: force reinstall jaraco.context to fix GHSA-58pv
This commit is contained in:
@@ -20,7 +20,8 @@ RUN pip install --no-cache-dir --upgrade "pip>=25.3" wheel
|
|||||||
|
|
||||||
# Install Python dependencies (includes security pins from requirements.txt)
|
# Install Python dependencies (includes security pins from requirements.txt)
|
||||||
COPY requirements.txt .
|
COPY requirements.txt .
|
||||||
RUN pip install --no-cache-dir -r requirements.txt gunicorn
|
RUN pip install --no-cache-dir -r requirements.txt gunicorn && \
|
||||||
|
pip install --no-cache-dir --force-reinstall "jaraco.context>=6.1.0"
|
||||||
|
|
||||||
|
|
||||||
# Stage 2: Alpine runtime (minimal)
|
# Stage 2: Alpine runtime (minimal)
|
||||||
@@ -32,7 +33,9 @@ LABEL description="Minimal secure pastebin REST API (Alpine)"
|
|||||||
# Apply security fixes to base image (versions from requirements.txt)
|
# Apply security fixes to base image (versions from requirements.txt)
|
||||||
COPY requirements.txt /tmp/
|
COPY requirements.txt /tmp/
|
||||||
RUN pip install --no-cache-dir --upgrade pip && \
|
RUN pip install --no-cache-dir --upgrade pip && \
|
||||||
pip install --no-cache-dir -r /tmp/requirements.txt && rm /tmp/requirements.txt
|
pip install --no-cache-dir -r /tmp/requirements.txt && \
|
||||||
|
pip install --no-cache-dir --force-reinstall "jaraco.context>=6.1.0" && \
|
||||||
|
rm /tmp/requirements.txt
|
||||||
|
|
||||||
# Create non-root user
|
# Create non-root user
|
||||||
RUN addgroup -g 65532 -S flaskpaste && adduser -u 65532 -S -G flaskpaste flaskpaste
|
RUN addgroup -g 65532 -S flaskpaste && adduser -u 65532 -S -G flaskpaste flaskpaste
|
||||||
|
|||||||
Reference in New Issue
Block a user