-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* refactor: 서브모듈 위치 변경 및 업데이트 * feat: 새로운 개발 환경에 맞춘 CD Github Action 수정 * fix: Dockerfile 경로 수정 * fix: Dockerfile 내부 jar 파일 경로 수정 * fix: Docker push 직접 스크립트 사용하도록 변경 * fix: Docker push 스크립트 수정 * feat: 서브 모듈 업데이트
- Loading branch information
1 parent
ca21e27
commit 07dc38c
Showing
6 changed files
with
22 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,8 @@ on: | |
push: | ||
branches: | ||
- dev | ||
paths: 'backend/**' | ||
paths: | ||
- 'backend/**' | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
|
@@ -37,22 +38,23 @@ jobs: | |
- name: bootJar with gradle | ||
run: ./gradlew bootJar | ||
|
||
# 2023-11-23 기준 EC2 프리티어 사용으로 인해 DEV 환경을 PROD 환경에서 실행함 | ||
- name: deploy use scp | ||
uses: appleboy/scp-action@master | ||
- name: Docker Login | ||
uses: docker/[email protected] | ||
with: | ||
host: ${{secrets.FESTAGO_PROD_IP}} | ||
username: ${{secrets.FESTAGO_PROD_USERNAME}} | ||
key: ${{secrets.FESTAGO_SSH_KEY}} | ||
source: "./backend/build/libs/*.jar" | ||
target: ${{ vars.FESTAGO_PROD_JAR_DIR }} | ||
strip_components: 3 | ||
username: ${{ vars.DOCKER_HUB_DEV_USERNAME }} | ||
password: ${{ secrets.DOCKER_HUB_DEV_LOGIN_TOKEN }} | ||
|
||
- name: Build Docker images | ||
run: docker build -t ${{ vars.DOCKER_DEV_TAG }} . | ||
|
||
- name: Push Docker images | ||
run: docker push ${{ vars.DOCKER_DEV_TAG }} | ||
|
||
- name: run application use ssh | ||
uses: appleboy/ssh-action@master | ||
with: | ||
host: ${{secrets.FESTAGO_PROD_IP}} | ||
username: ${{secrets.FESTAGO_PROD_USERNAME}} | ||
key: ${{secrets.FESTAGO_SSH_KEY}} | ||
host: ${{ vars.FESTAGO_DEV_IP }} | ||
username: ${{ vars.FESTAGO_DEV_USERNAME }} | ||
key: ${{secrets.FESTAGO_DEV_SSH_KEY}} | ||
script_stop: true | ||
script: ${{ vars.FESTAGO_DEV_DEPLOY_COMMAND }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
[submodule "backend/src/main/resources/festago-config"] | ||
path = backend/src/main/resources/festago-config | ||
[submodule "backend/src/main/resources/config"] | ||
path = backend/src/main/resources/config | ||
url = https://github.com/festago/festago-config.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
FROM openjdk:17-jdk | ||
ARG JAR_FILE_PATH=./build/libs/*.jar | ||
COPY ${JAR_FILE_PATH} app.jar | ||
ENTRYPOINT ["java", "-jar", "-Duser.timezone=Asia/Seoul", "app.jar"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,3 @@ | ||
spring: | ||
profiles: | ||
active: local | ||
config: | ||
import: | ||
- classpath:/festago-config/backend/application-dev.yml | ||
- classpath:/festago-config/backend/application-prod.yml | ||
- classpath:/festago-config/backend/application-infra.yml |
Submodule festago-config
deleted from
691d66