diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b6461f8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM python:3.9-slim + +# Create working folder and install dependencies +WORKDIR /app +COPY requirements.txt . +RUN pip install --no-cache-dir -r requirements.txt + +# Copy the application contents +COPY service/ ./service/ + +# Switch to a non-root user +RUN useradd --uid 1000 theia && chown -R theia /app +USER theia + +# Run the service +EXPOSE 8080 +CMD ["gunicorn", "--bind=0.0.0.0:8080", "--log-level=info", "service:app"] \ No newline at end of file