Skip to content

Commit e3d4ba5

Browse files
committed
feat: Dockerfile 작성
- 경량화 된 베이스 이미지 사용으로 이미지 용량 최적화 - 멀티 스테이지 빌드 수행
1 parent 786f661 commit e3d4ba5

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

Dockerfile

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
FROM gradle:8.12.1-jdk21-alpine AS build
2+
WORKDIR /home/gradle/project
3+
4+
COPY build.gradle settings.gradle ./
5+
COPY gradle gradle/
6+
7+
COPY src src
8+
9+
RUN gradle clean build
10+
11+
FROM eclipse-temurin:21-jre-alpine
12+
WORKDIR /app
13+
14+
COPY --from=build /home/gradle/project/build/libs/dmu-dasom-api.jar api.jar
15+
16+
ENTRYPOINT ["java", "-Dspring.profiles.active=default,credentials", "-jar", "api.jar"]

0 commit comments

Comments
 (0)