switching to alpine and using git.allucanget.biz docker registry
Some checks failed
Build and Deploy Docker Container / build-and-deploy (push) Failing after 2m1s
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 3s

This commit is contained in:
2025-09-19 21:18:02 +02:00
parent 118269935d
commit 4b6ecf1726
3 changed files with 48 additions and 9 deletions

View File

@@ -1,12 +1,9 @@
# Use official Python image
FROM python:3.11-slim
FROM python:3.12-alpine
# Set working directory
WORKDIR /app
# Install system dependencies if needed (none for this app)
# RUN apt-get update && apt-get install -y gcc && rm -rf /var/lib/apt/lists/*
# Copy requirements and install Python dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
@@ -15,8 +12,8 @@ RUN pip install --no-cache-dir -r requirements.txt
COPY . .
# Create a non-root user
RUN useradd --create-home --shell /bin/bash app
USER app
RUN addgroup -S appgroup && adduser -S appuser -G appgroup
USER appuser
# Command to run the application
CMD ["python", "main.py"]