Team Ai
Apppublic

hadokenvskikoken/codegen_api

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes
Dockerfile32 linesDownload Raw Back to root
1FROM python:3.9-slim2 3WORKDIR /app4 5# Install system dependencies6RUN apt-get update && apt-get install -y \7    git \8    gcc \9    g++ \10    make \11    && rm -rf /var/lib/apt/lists/*12 13# Create cache directory14RUN mkdir -p /.cache && chmod -R 777 /.cache15 16# Set environment variables17ENV TRANSFORMERS_CACHE=/.cache18ENV HF_HOME=/.cache19ENV HUGGINGFACE_HUB_CACHE=/.cache20 21# Install Python dependencies22COPY requirements.txt .23RUN pip install --no-cache-dir -r requirements.txt24 25# Copy application code26COPY main.py .27 28# Expose port29EXPOSE 786030 31# Run the API32CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]