Initialize git-contribution-graph project with Docker setup, environment configuration, and core functionality for merging contributions from GitHub, GitLab, and Gitea into an SVG heatmap.

This commit is contained in:
2026-05-28 19:35:44 +02:00
commit 342490035b
17 changed files with 881 additions and 0 deletions
+41
View File
@@ -0,0 +1,41 @@
FROM php:8.3-cli-alpine AS base
# Runtime dependencies
RUN apk add --no-cache \
curl \
icu-libs \
libzip \
&& docker-php-ext-install opcache
# Composer
COPY --from=composer:2 /usr/bin/composer /usr/bin/composer
WORKDIR /app
# ── deps stage ────────────────────────────────────────────────────────────────
FROM base AS deps
COPY composer.json composer.lock* ./
RUN composer install \
--no-dev \
--no-scripts \
--no-interaction \
--optimize-autoloader \
--prefer-dist
# ── final stage ───────────────────────────────────────────────────────────────
FROM base AS final
COPY --from=deps /app/vendor /app/vendor
COPY . .
RUN mkdir -p var/cache var/log \
&& chmod -R 777 var \
&& composer dump-autoload --optimize --no-dev
EXPOSE 8080
ENV APP_ENV=prod \
APP_DEBUG=0
# Symfony's built-in dev server via PHP — fine for a single-purpose container
CMD ["php", "-S", "0.0.0.0:8080", "-t", "public", "public/index.php"]