From 0049c19c4fb21af0ee4f925ef0f08ee726b2dd22 Mon Sep 17 00:00:00 2001 From: bo Date: Thu, 2 May 2024 17:19:27 +0900 Subject: [PATCH] =?UTF-8?q?chore(docker):=20docker=20=EC=84=A4=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker-compose.yml | 36 ------------------------- Dockerfile => logging-server/Dockerfile | 2 +- main-server/Dockerfile | 4 +++ main-server/build.gradle | 2 +- 4 files changed, 6 insertions(+), 38 deletions(-) delete mode 100644 docker-compose.yml rename Dockerfile => logging-server/Dockerfile (71%) create mode 100644 main-server/Dockerfile diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index dec5cb3..0000000 --- a/docker-compose.yml +++ /dev/null @@ -1,36 +0,0 @@ -version: '3' - -services: - database: - env_file: - - .env - container_name: mysql_db - image: mysql/mysql-server:8.0-aarch64 - restart: unless-stopped - environment: - MYSQL_DATABASE: ${DATABASE} - MYSQL_ROOT_HOST: ${HOST} - MYSQL_ROOT_PASSWORD: ${PASSWORD} - TZ: 'Asia/Seoul' - - volumes: - - ./mysql/conf.d:/etc/mysql/conf.d # MySQL 설정 파일 위치 - command: - - "mysqld" - - "--character-set-server=utf8mb4" - - "--collation-server=utf8mb4_unicode_ci" - networks: - - test_network - - application: - env_file: - - .env - container_name: spring-project - restart: on-failure - image: jacobhboy/sickgyun-server:0.0.1 - ports: - - "8080:8080" - depends_on: - - database - networks: - - test_network \ No newline at end of file diff --git a/Dockerfile b/logging-server/Dockerfile similarity index 71% rename from Dockerfile rename to logging-server/Dockerfile index 2182be4..7fc68d2 100644 --- a/Dockerfile +++ b/logging-server/Dockerfile @@ -1,4 +1,4 @@ FROM openjdk:21-jdk -ARG JAR_FILE=build/libs/*.jar +ARG JAR_FILE=./build/libs/*.jar COPY ${JAR_FILE} app.jar ENTRYPOINT ["java","-jar","/app.jar"] \ No newline at end of file diff --git a/main-server/Dockerfile b/main-server/Dockerfile new file mode 100644 index 0000000..c9b5eb7 --- /dev/null +++ b/main-server/Dockerfile @@ -0,0 +1,4 @@ +FROM eclipse-temurin:21-jdk +ARG JAR_FILE=./build/libs/*.jar +COPY ${JAR_FILE} app.jar +ENTRYPOINT ["java","-jar","/app.jar"] \ No newline at end of file diff --git a/main-server/build.gradle b/main-server/build.gradle index 6de03de..5d8f3a5 100644 --- a/main-server/build.gradle +++ b/main-server/build.gradle @@ -67,5 +67,5 @@ bootJar { } jar { - enabled = true + enabled = false } \ No newline at end of file