Skip to content

Commit

Permalink
refactor: Docker 빌드 성능 개선 (#138)
Browse files Browse the repository at this point in the history
  • Loading branch information
kunsanglee authored Jul 26, 2024
1 parent b0f0ffa commit d056d28
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/backend-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v3.1.0

- name: Test with Gradle Wrapper
run: ./gradlew test
run: ./gradlew clean build

- name: Login to Docker Hub
uses: docker/login-action@v3
Expand Down
10 changes: 1 addition & 9 deletions server/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,8 @@
FROM gradle:7.6.1-jdk17 AS build

WORKDIR /app

COPY . /app

RUN gradle clean build -x test

FROM openjdk:17-jdk-slim

WORKDIR /app

COPY --from=build /app/build/libs/*.jar /app/haengdong-0.0.1-SNAPSHOT.jar
COPY /build/libs/*.jar /app/haengdong-0.0.1-SNAPSHOT.jar

EXPOSE 8080
ENTRYPOINT ["java"]
Expand Down

0 comments on commit d056d28

Please sign in to comment.