Turkcell / Dockerfile
huseyinemretech's picture
Fix: Change npm ci to npm install in Dockerfile
b269754
Raw History Blame Contribute Delete
1.03 kB
# Multi-stage build for SesleAI
# Stage 1: Build Frontend
FROM node:20-alpine AS frontend-builder
WORKDIR /app/frontend
COPY frontend/package*.json ./
RUN npm install
COPY frontend/ ./
RUN npm run build
# Stage 2: Python Runtime
FROM python:3.11-slim
# Install system dependencies
RUN apt-get update && apt-get install -y \
nginx \
supervisor \
ffmpeg \
libsndfile1 \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Copy Python requirements and install
COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt
# Copy backend files
COPY backend/ ./backend/
COPY emotion_api/ ./emotion_api/
# Copy frontend build from previous stage
COPY --from=frontend-builder /app/frontend/dist /app/static
# Copy nginx config
COPY nginx.conf /etc/nginx/nginx.conf
# Copy supervisor config
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
# Expose port (HF Spaces uses 7860)
EXPOSE 7860
# Start supervisor
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"]