feat(infra): add multi-stage dockerfiles for PaaS deployment

This commit is contained in:
jade
2026-07-15 08:59:58 +09:00
parent 16b5b81ed4
commit e93b149cf9
6 changed files with 89 additions and 15 deletions

View File

@@ -1,4 +1,18 @@
FROM eclipse-temurin:21-jdk-alpine
FROM eclipse-temurin:21-jdk-alpine AS builder
WORKDIR /app
COPY build/libs/axhub-tool-email-0.0.1-SNAPSHOT.jar app.jar
COPY gradlew .
COPY gradle gradle
COPY build.gradle settings.gradle ./
COPY axhub-common axhub-common
COPY axhub-tool-core axhub-tool-core
COPY axhub-tool-email axhub-tool-email
RUN chmod +x gradlew
RUN ./gradlew :axhub-tool-email:build -x test
FROM eclipse-temurin:21-jre-alpine
WORKDIR /app
RUN apk add --no-cache tzdata
ENV TZ=Asia/Seoul
COPY --from=builder /app/axhub-tool-email/build/libs/*-SNAPSHOT.jar app.jar
EXPOSE 8083
ENTRYPOINT ["java", "-jar", "app.jar"]