🤖 ci: optimize CI/CD with Docker cache and remove Buildx
Some checks failed
CI/CD Pipeline / CI Pipeline (push) Has been cancelled
CI/CD Pipeline / Build Docker Cache (push) Has been cancelled

This commit is contained in:
2026-04-07 11:52:33 +02:00
parent c6a2d63a6d
commit 3029e93175
3 changed files with 156 additions and 49 deletions

35
Dockerfile.prod Normal file
View File

@@ -0,0 +1,35 @@
# DanceLessonsCoach Production Docker Image
# Minimal image using pre-built binary from CI cache
# Use the build cache image as base
FROM gitea.arcodange.lab/arcodange/dance-lessons-coach-build-cache:latest AS builder
# Final minimal image
FROM alpine:3.18
WORKDIR /app
# Install minimal dependencies
RUN apk add --no-cache ca-certificates tzdata
# Copy binary from builder
COPY --from=builder /workspace/dance-lessons-coach /app/dance-lessons-coach
# Copy configuration
COPY config.yaml /app/config.yaml
# Set permissions
RUN chmod +x /app/dance-lessons-coach
# Set timezone
ENV TZ=UTC
# Expose port
EXPOSE 8080
# Health check
HEALTHCHECK --interval=30s --timeout=3s \
CMD wget -q --spider http://localhost:8080/api/health || exit 1
# Entry point
ENTRYPOINT ["/app/dance-lessons-coach"]