Umfangreiches Refactoring der Projektkonfiguration zur klaren Trennung von Build-, Runtime- und Applikations-Logik. Änderungen im Detail: - Struktur: Neuorganisation des `config/` Verzeichnisses in logische Bereiche: - `config/docker`: Reine Infrastruktur-Configs (Postgres, Redis, Nginx, Monitoring). - `config/quality`: Statische Code-Analyse (Detekt, Lint). - `config/app`: Gemeinsame Spring-Boot-Konfigurationen. - Docker Compose: - Einführung von Profilen (`infra`, `backend`, `ops`, `gui`, `tools`) für gezieltes Starten von Teilbereichen. - Anpassung aller Volume-Pfade auf die neue Struktur. - Spring Boot Config: - Zentralisierung gemeinsamer Einstellungen (Datasource, Redis, JPA) in `config/app/base-application.yml`. - Parametrisierung der Hosts für nahtlosen Wechsel zwischen Docker und Localhost. - Bereinigung der service-spezifischen `application.yaml` Dateien (z.B. Ping-Service). - Cleanup: Entfernen redundanter "Ghost-Files" (`versions.toml`, `central.toml`, `config/.env`), um eine echte Single Source of Truth (SSoT) zu gewährleisten.
37 lines
1.0 KiB
Docker
37 lines
1.0 KiB
Docker
# syntax=docker/dockerfile:1.8
|
|
# ===================================================================
|
|
# Production-Ready Keycloak Dockerfile
|
|
# ===================================================================
|
|
# Based on: quay.io/keycloak/keycloak:26.4
|
|
# Features:
|
|
# - Pre-built optimized image (faster startup)
|
|
# - Security hardening
|
|
# - Custom theme support
|
|
# - Health monitoring
|
|
# ===================================================================
|
|
ARG KEYCLOAK_IMAGE_TAG
|
|
|
|
FROM quay.io/keycloak/keycloak:${KEYCLOAK_IMAGE_TAG}
|
|
|
|
LABEL maintainer="Meldestelle Development Team"
|
|
LABEL description="Production-ready Keycloak for Meldestelle authentication"
|
|
LABEL version="${KEYCLOAK_IMAGE_TAG}"
|
|
|
|
# Set environment variables for build
|
|
ENV KC_HEALTH_ENABLED=true
|
|
ENV KC_METRICS_ENABLED=true
|
|
ENV KC_DB=postgres
|
|
|
|
WORKDIR /opt/keycloak
|
|
|
|
# Pre-build Keycloak for faster startup
|
|
RUN /opt/keycloak/bin/kc.sh build \
|
|
--db=postgres \
|
|
--health-enabled=true \
|
|
--metrics-enabled=true
|
|
|
|
# Set user
|
|
USER 1000
|
|
|
|
ENTRYPOINT ["/opt/keycloak/bin/kc.sh"]
|