From 088d9e2a5a1063db53b546e4b0698fcc0a95e78c Mon Sep 17 00:00:00 2001 From: Jaehyeon Date: Tue, 9 Jan 2024 00:01:13 +0900 Subject: [PATCH] Feat: set main class for jib --- daepiro-api/build.gradle | 1 + .../src/main/java/com/numberone/backend/BackendApplication.java | 2 ++ 2 files changed, 3 insertions(+) diff --git a/daepiro-api/build.gradle b/daepiro-api/build.gradle index a755aeae..6db5541a 100644 --- a/daepiro-api/build.gradle +++ b/daepiro-api/build.gradle @@ -68,6 +68,7 @@ jib { tags = ["latest"] } container { + mainClass = 'com.numberone.backend.BackendApplication' jvmFlags = ["-Duser.timezone=Asia/Seoul", "-Xms128m", "-Xmx128m"] } } diff --git a/daepiro-api/src/main/java/com/numberone/backend/BackendApplication.java b/daepiro-api/src/main/java/com/numberone/backend/BackendApplication.java index 8cfd171d..3fb21b3a 100644 --- a/daepiro-api/src/main/java/com/numberone/backend/BackendApplication.java +++ b/daepiro-api/src/main/java/com/numberone/backend/BackendApplication.java @@ -2,8 +2,10 @@ import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.boot.web.servlet.ServletComponentScan; @SpringBootApplication +@ServletComponentScan public class BackendApplication { public static void main(String[] args) { SpringApplication.run(BackendApplication.class, args);