Spaces:
Paused
Paused
Update Dockerfile
Browse files1234567891011121314151617181920FROM python:3.9.5-busterRUN apt update && apt upgrade -yRUN apt-get install git curl python3-pip ffmpeg -yRUN apt-get -y install gitRUN apt-get install -y wget python3-pip curl bash neofetch ffmpeg software-properties-commonWORKDIR /appCOPY . /appRUN pip3 install --no-cache-dir -U pip redis fastapi nest-asyncio uvicorn && \pip3 install --no-cache-dir -r requirements.txtRUN chown -R 1000:0 /app /usr && \chmod -R 755 /app /usr && \chmod 777 /app/start && \chmod +x /app/startRUN ls /appEXPOSE 5000 8000#CMD python3 -m devgagan & flask run -h 0.0.0.0 -p 8000# CMD gunicorn app:app & python3 -m devgaganCMD ["./start"]12345678910111213141516171819202122232425262728293031323334# Use a modern, supported Debian base (Bookworm)FROM python:3.9-slim-bookworm# Set environment variables to keep apt quietENV DEBIAN_FRONTEND=noninteractive# Combine updates and installs into one layer to save spaceRUN apt-get update && apt-get upgrade -y && \apt-get install -y --no-install-recommends \git \curl \wget \bash \neofetch \ffmpeg \software-properties-common && \rm -rf /var/lib/apt/lists/*WORKDIR /appCOPY . /app# Upgrade pip and install requirementsRUN pip3 install --no-cache-dir -U pip redis fastapi nest-asyncio uvicorn && \pip3 install --no-cache-dir -r requirements.txt# Permissions# Note: Changing permissions on /usr is generally discouraged unless strictly necessaryRUN chown -R 1000:0 /app && \chmod -R 755 /app && \chmod +x /app/startEXPOSE 5000 8000CMD ["./start"]
Dockerfile+26-12