pong / Dockerfile
chrisxx's picture
Add libevent-dev and verify eventlet installation
99b7515
raw
history blame
681 Bytes
FROM nvidia/cuda:12.1.0-base-ubuntu22.04
# Install Python 3.11, pip, and build tools
RUN apt-get update && \
apt-get install -y python3.11 python3.11-dev python3-pip build-essential libevent-dev && \
ln -sf /usr/bin/python3.11 /usr/bin/python && \
ln -sf /usr/bin/pip3 /usr/bin/pip && \
pip install --upgrade pip setuptools wheel && \
rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt && \
python -c "import eventlet; print('eventlet version:', eventlet.__version__)" && \
rm -rf ~/.cache/pip
# Copy source code
COPY . .
EXPOSE 7860
CMD ["python", "app.py"]