Skip to content

Commit

Permalink
chore : yml 환경변수 재구성 (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
zuminzi committed Oct 8, 2023
1 parent da5fdfc commit 06781f0
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 12 deletions.
2 changes: 1 addition & 1 deletion 4Week_Mission/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ dependencies {
implementation 'org.mapstruct:mapstruct:1.5.3.Final'
compileOnly 'org.projectlombok:lombok'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
runtimeOnly 'org.mariadb.jdbc:mariadb-java-client'
implementation 'mysql:mysql-connector-java'
runtimeOnly 'io.jsonwebtoken:jjwt-impl:0.11.5'
runtimeOnly 'io.jsonwebtoken:jjwt-jackson:0.11.5'
annotationProcessor 'org.projectlombok:lombok'
Expand Down
6 changes: 3 additions & 3 deletions 4Week_Mission/src/main/resources/application-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ spring:
restart:
enabled: true
datasource:
url: jdbc:mariadb://127.0.0.1:3306/ebook_market__dev?useUnicode=true&characterEncoding=utf8&autoReconnect=true&serverTimezone=Asia/Seoul
username: user1
password: Ttest12341234@
url: jdbc:mysql://127.0.0.1:3306/ebook_market__dev?useUnicode=true&characterEncoding=utf8&autoReconnect=true&serverTimezone=Asia/Seoul
username: ${DEV_DB_USERNAME}
password: ${DEV_DB_PASSWORD}
jpa:
hibernate:
ddl-auto: create
11 changes: 11 additions & 0 deletions 4Week_Mission/src/main/resources/application-prod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
spring:
datasource:
url: jdbc:mysql://${DB_HOST}:3306/ebook_market__prod?useUnicode=true&characterEncoding=utf8&serverTimeZone=Asia/Seoul&allowPublicKeyRetrieval=true&useSSL=false
username: ${DB_USERNAME}
password: ${DB_PASSWORD}
jpa:
hibernate:
ddl-auto: none
logging:
level:
root: info
6 changes: 3 additions & 3 deletions 4Week_Mission/src/main/resources/application-test.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
spring:
datasource:
url: jdbc:mariadb://${testDbIp:127.0.0.1}:3306/ebook_market__test?useUnicode=true&characterEncoding=utf8&autoReconnect=true&serverTimezone=Asia/Seoul
username: ${testDbId:user1}
password: ${testDbPw:Ttest12341234@}
url: jdbc:mysql://${TEST_DB_HOST:127.0.0.1}:3306/ebook_market__test?useUnicode=true&characterEncoding=utf8&autoReconnect=true&serverTimezone=Asia/Seoul
username: ${TEST_DB_USERNAME}
password: ${TEST_DB_PASSWORD}
jpa:
hibernate:
ddl-auto: create
15 changes: 10 additions & 5 deletions 4Week_Mission/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ spring:
- base-addi
batch:
job:
names: ${job.name:none}
names: ${JOB_NAME:none}
month:
jdbc:
initialize-schema: ALWAYS
datasource:
driver-class-name: org.mariadb.jdbc.Driver
driver-class-name: com.mysql.cj.jdbc.Driver
jpa:
properties:
hibernate:
Expand All @@ -20,13 +20,18 @@ spring:
mail:
host: smtp.gmail.com
port: 587
username:
password:
username: ${MAIL_USERNAME}
password: ${MAIL_PASSWORD}
properties:
mail.smtp.auth: true
mail.smtp.ssl.enable: true
mail.smtp.ssl.trust: smtp.gmail.com
mail.smtp.starttls.enable: true
custom:
toss-payments:
secret-key: ${TOSS_SECRET_KEY}
jwt:
secret-key: ${JWT_SECRET_KEY}
logging:
level:
root: info
Expand All @@ -39,4 +44,4 @@ custom:
wholesalePriceRate: 0.5
site:
name: MEOTBOOKS
baseUrl: "http://localhost:8010"
baseUrl: "http://localhost:8010"

0 comments on commit 06781f0

Please sign in to comment.