quantumtaskai-caprover/Dockerfile.dokploy
thecyberlearn 98cc088518 Fix Dokploy deployment 404 errors
- Updated Dockerfile.dokploy with proper startup script
- Added start-dokploy.sh for database migrations and health checks
- Enhanced dokploy.json with required environment variables
- Added debug Dockerfile for troubleshooting (Dockerfile.dokploy.debug)
- Added debug config (dokploy.debug.json) for testing
- Fixed static file collection and gunicorn configuration
- Improved error handling and logging for deployment issues
2025-09-05 09:22:06 +05:30

33 lines
690 B
Docker

FROM python:3.11-slim
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
gcc \
libpq-dev \
&& rm -rf /var/lib/apt/lists/*
# Copy and install Python dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY . .
# Set environment variables
ENV PYTHONUNBUFFERED=1 \
SECRET_KEY="build-time-dummy-key-change-in-production"
# Collect static files
RUN python manage.py collectstatic --noinput --settings=netcop_hub.settings
# Make startup script executable
RUN chmod +x start-dokploy.sh
# Expose port 3000 for Dokploy
EXPOSE 3000
# Use startup script
CMD ["./start-dokploy.sh"]