Skip to content
This repository has been archived by the owner on Jul 29, 2024. It is now read-only.

[BE] chore: 백엔드 application.properties submodule로 관리 #372

Merged
merged 4 commits into from
Sep 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/build-be-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ jobs:
steps:
## jdk setting
- uses: actions/checkout@v3
with:
submodules: true
token: ${{ secrets.SUBMODULE_TOKEN }}
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/build-be-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ jobs:
steps:
## jdk setting
- uses: actions/checkout@v3
with:
submodules: true
token: ${{ secrets.SUBMODULE_TOKEN }}
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
Expand Down
12 changes: 0 additions & 12 deletions .github/workflows/deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,8 @@ jobs:
run: |
touch .env
echo "DOCKER_USERNAME=${{ secrets.DOCKER_USERNAME }}" >> .env
echo "DB_URL=${{ secrets.DEV_DB_URL }}" >> .env
echo "DB_USERNAME=${{ secrets.DB_USERNAME }}" >> .env
echo "DB_PASSWORD=${{ secrets.DB_PASSWORD }}" >> .env
echo "SPRING_PROFILES_ACTIVE=${{ vars.SPRING_PROFILES_ACTIVE_DEVELOPMENT }}" >> .env
echo "INFRA_PROFILE=${{ vars.INFRA_PROFILE_DEVELOPMENT }}" >> .env
echo "KAKAO_CLIENT_ID=${{ secrets.KAKAO_CLIENT_ID }}" >> .env
echo "KAKAO_CLIENT_SECRET=${{ secrets.KAKAO_CLIENT_SECRET }}" >> .env
echo "TISTORY_CLIENT_ID=${{ secrets.TISTORY_CLIENT_ID }}" >> .env
echo "TISTORY_CLIENT_SECRET=${{ secrets.TISTORY_CLIENT_SECRET }}" >> .env
echo "NOTION_CLIENT_ID=${{ secrets.NOTION_CLIENT_ID }}" >> .env
echo "NOTION_CLIENT_SECRET=${{ secrets.NOTION_CLIENT_SECRET }}" >> .env
echo "JWT_SECRET_KEY=${{ secrets.JWT_SECRET_KEY }}" >> .env
echo "ACCESS_TOKEN_EXPIRE_LENGTH=${{ secrets.ACCESS_TOKEN_EXPIRE_LENGTH }}" >> .env
echo "REFRESH_TOKEN_EXPIRE_LENGTH=${{ secrets.REFRESH_TOKEN_EXPIRE_LENGTH }}" >> .env
## deploy to production
- name: Deploy to prod
run: |
Expand Down
12 changes: 0 additions & 12 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,8 @@ jobs:
run: |
touch .env
echo "DOCKER_USERNAME=${{ secrets.DOCKER_USERNAME }}" >> .env
echo "DB_URL=${{ secrets.PROD_DB_URL }}" >> .env
echo "DB_USERNAME=${{ secrets.DB_USERNAME_PROD }}" >> .env
echo "DB_PASSWORD=${{ secrets.DB_PASSWORD_PROD }}" >> .env
echo "SPRING_PROFILES_ACTIVE=${{ vars.SPRING_PROFILES_ACTIVE_PRODUCTION }}" >> .env
echo "INFRA_PROFILE=${{ vars.INFRA_PROFILE_PRODUCTION}}" >> .env
echo "KAKAO_CLIENT_ID=${{ secrets.KAKAO_CLIENT_ID }}" >> .env
echo "KAKAO_CLIENT_SECRET=${{ secrets.KAKAO_CLIENT_SECRET }}" >> .env
echo "TISTORY_CLIENT_ID=${{ secrets.TISTORY_CLIENT_ID_PROD }}" >> .env
echo "TISTORY_CLIENT_SECRET=${{ secrets.TISTORY_CLIENT_SECRET_PROD }}" >> .env
echo "NOTION_CLIENT_ID=${{ secrets.NOTION_CLIENT_ID }}" >> .env
echo "NOTION_CLIENT_SECRET=${{ secrets.NOTION_CLIENT_SECRET }}" >> .env
echo "JWT_SECRET_KEY=${{ secrets.JWT_SECRET_KEY }}" >> .env
echo "ACCESS_TOKEN_EXPIRE_LENGTH=${{ secrets.ACCESS_TOKEN_EXPIRE_LENGTH }}" >> .env
echo "REFRESH_TOKEN_EXPIRE_LENGTH=${{ secrets.REFRESH_TOKEN_EXPIRE_LENGTH }}" >> .env
## deploy to production
- name: Deploy to prod
run: |
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "backend/src/main/resources/config"]
path = backend/src/main/resources/config
url = https://github.com/d0ng-gle/security.git
32 changes: 0 additions & 32 deletions backend/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,35 +25,3 @@ tistory_client_id: tistory_client_id
tistory_client_secret: tistory_client_secret
notion_client_id: notion_client_id
notion_client_secret: notion_client_secret
---
spring:
config:
activate:
on-profile: dev, prod
datasource:
url: ${DB_URL}
username: ${DB_USERNAME}
password: ${DB_PASSWORD}
jpa:
hibernate:
ddl-auto: none
security:
jwt:
token:
secret-key: ${JWT_SECRET_KEY}
access-token-expire-length: ${ACCESS_TOKEN_EXPIRE_LENGTH}
refresh-token-expire-length: ${REFRESH_TOKEN_EXPIRE_LENGTH}
kakao_client_id: ${KAKAO_CLIENT_ID}
kakao_client_secret: ${KAKAO_CLIENT_SECRET}
tistory_client_id: ${TISTORY_CLIENT_ID}
tistory_client_secret: ${TISTORY_CLIENT_SECRET}
notion_client_id: ${NOTION_CLIENT_ID}
notion_client_secret: ${NOTION_CLIENT_SECRET}
---
spring:
config:
activate:
on-profile: dev
jpa:
hibernate:
ddl-auto: create
1 change: 1 addition & 0 deletions backend/src/main/resources/config
Submodule config added at 699acf
12 changes: 0 additions & 12 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,6 @@ services:
- /home/ubuntu/logs/:/logs/
environment:
- SPRING_PROFILES_ACTIVE
- DB_URL
- DB_USERNAME
- DB_PASSWORD
- KAKAO_CLIENT_ID
- KAKAO_CLIENT_SECRET
- TISTORY_CLIENT_ID
- TISTORY_CLIENT_SECRET
- NOTION_CLIENT_ID
- NOTION_CLIENT_SECRET
- JWT_SECRET_KEY
- ACCESS_TOKEN_EXPIRE_LENGTH
- REFRESH_TOKEN_EXPIRE_LENGTH

nginx:
container_name: nginx
Expand Down