feat: auto-start Spring Boot backend via docker-compose

Replace the devcontainer (sleep infinity + VS Code image) with a proper
dev setup:
- Dockerfile: eclipse-temurin:21-jdk-alpine running ./mvnw spring-boot:run
- Source mounted at /app, Maven deps cached in named volume maven_cache
- Healthcheck on /actuator/health so frontend waits until backend is ready
- frontend depends_on backend: service_healthy (was service_started)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-03-17 22:19:59 +01:00
parent 3280125140
commit 9b67db74eb
2 changed files with 18 additions and 11 deletions

View File

@@ -1,8 +1,9 @@
# Wir nutzen Java 21 (LTS), da Spring Boot 3 das empfiehlt
FROM mcr.microsoft.com/devcontainers/java:1-21-bullseye
FROM eclipse-temurin:21-jdk-alpine
# Optional: Zusätzliche OS-Pakete installieren
# RUN apt-get update && apt-get install -y <package-name>
WORKDIR /app
# Port für Spring Boot
EXPOSE 8080
# Source code and mvnw are mounted via docker-compose volume at runtime.
# Maven dependencies are cached in a named volume (~/.m2).
CMD ["./mvnw", "spring-boot:run"]