-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
FROM ghcr.io/usace/usace-wm-python:3.13
# Set working directory
WORKDIR /code
# Install dependencies as root into system Python
COPY requirements.txt .
COPY requirements-dev.txt .
USER root
RUN python -m pip install --no-cache-dir -r requirements.txt \
&& python -m pip install --no-cache-dir -r requirements-dev.txt
# Copy app code
COPY ./cwms_batch_events/api ./cwms_batch_events/api
# Expose port
EXPOSE 8000
# Switch to non-root user
USER appuser
# Run using python -m uvicorn (ensures system packages are used)
CMD ["python", "-m", "uvicorn", \
"cwms_batch_events.api.main:app", \
"--workers", "2", \
"--worker-class", "uvicorn.workers.UvicornWorker", \
"--bind", "0.0.0.0:8000", \
"--access-logfile", "-", \
"--error-logfile", "-"]
requires adding requests to your requirements.txt
@jbkolze FYI
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels