Skip to content

Commit fee3e9d

Browse files
committed
[Feat]: 배포 환경설정
1 parent e61d326 commit fee3e9d

File tree

5 files changed

+38
-8
lines changed

5 files changed

+38
-8
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ db_dev.mv.db
4141
db_dev.trace.db
4242
src/main/generated/
4343
k6-tests/results
44+
*.pem
45+
*.key
4446

4547
### env ###
4648
.env

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# WEB6_8_Bid_BE
2-
프로그래머스 6기 8회차 최종 프로젝트 12팀(Bid)
2+
3+
프로그래머스 6기 8회차 최종 프로젝트 12팀(Bid) - 백엔드

build.gradle.kts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ dependencies {
4848

4949
// DB
5050
runtimeOnly("com.h2database:h2")
51+
runtimeOnly("com.mysql:mysql-connector-j")
5152

5253
// QueryDSL
5354
implementation("io.github.openfeign.querydsl:querydsl-jpa:7.0")

src/main/java/com/backend/global/security/SecurityConfig.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,13 @@ public UrlBasedCorsConfigurationSource corsConfigurationSource() {
6666
CorsConfiguration configuration = new CorsConfiguration();
6767

6868
// 허용할 오리진 설정
69-
configuration.setAllowedOrigins(List.of("https://cdpn.io", "http://localhost:3000"));
69+
configuration.setAllowedOrigins(List.of(
70+
"https://cdpn.io",
71+
"http://localhost:3000",
72+
"https://bid-market.shop",
73+
"https://www.bid-market.shop",
74+
"https://api.bid-market.shop"
75+
));
7076
configuration.setAllowedMethods(List.of("GET", "POST", "PUT", "PATCH", "DELETE"));
7177

7278
// 자격 증명 허용 설정
Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,34 @@
11
spring:
22
datasource:
3-
url: jdbc:h2:mem:db_test;MODE=MySQL
4-
username: sa
5-
password:
6-
driver-class-name: org.h2.Driver
3+
url: jdbc:mysql://${DB_HOST}:3306/${DB_NAME}?useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Seoul
4+
username: ${DB_USERNAME}
5+
password: ${DB_PASSWORD}
6+
driver-class-name: com.mysql.cj.jdbc.Driver
7+
8+
jpa:
9+
hibernate:
10+
ddl-auto: validate
11+
properties:
12+
hibernate:
13+
dialect: org.hibernate.dialect.MySQL8Dialect
14+
15+
data:
16+
redis:
17+
host: ${REDIS_HOST:localhost}
18+
port: ${REDIS_PORT:6379}
19+
20+
jwt:
21+
secret: ${JWT_SECRET}
22+
access_token_expiration_minutes: ${JWT_ACCESS_TOKEN_EXPIRATION:30}
23+
refresh_token_expiration_days: ${JWT_REFRESH_TOKEN_EXPIRATION:7}
724

825
file:
926
upload:
1027
path: ${user.home}/uploads
11-
base-url: ${BACKEND_BASE_URL}/uploads
28+
base-url: https://api.bid-market.shop/uploads
1229
testdata:
1330
generation:
14-
enabled: false
31+
enabled: false
32+
33+
server:
34+
port: 8080

0 commit comments

Comments
 (0)