Skip to content

Commit cbccb5b

Browse files
authored
Merge pull request #1 from prgrms-web-devcourse-final-project/feat/init-setup
backend, infra dir add
2 parents 17a7216 + 8ec1988 commit cbccb5b

24 files changed

+940
-0
lines changed

backend/.env.default

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
SPRING__SECURITY__OAUTH2__CLIENT__REGISTRATION__KAKAO__CLIENT_ID=NEED_TO_SET
2+
SPRING__SECURITY__OAUTH2__CLIENT__REGISTRATION__GOOGLE__CLIENT_ID=NEED_TO_SET
3+
SPRING__SECURITY__OAUTH2__CLIENT__REGISTRATION__GOOGLE__CLIENT_SECRET=NEED_TO_SET
4+
SPRING__SECURITY__OAUTH2__CLIENT__REGISTRATION__NAVER__CLIENT_ID=NEED_TO_SET
5+
SPRING__SECURITY__OAUTH2__CLIENT__REGISTRATION__NAVER__CLIENT_SECRET=NEED_TO_SET
6+
7+
CUSTOM__JWT__SECRET_KEY=NEED_TO_SET
8+
9+
REDIS_HOST=NEED_TO_SET
10+
REDIS_PORT=NEED_TO_SET
11+
12+
DB_HOST=NEED_TO_SET
13+
DB_PORT=NEED_TO_SET
14+
DB_NAME=NEED_TO_SET
15+
DB_USER=NEED_TO_SET
16+
DB_PASS=NEED_TO_SET

backend/.gitattributes

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
/gradlew text eol=lf
2+
*.bat text eol=crlf
3+
*.jar binary

backend/.gitignore

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
HELP.md
2+
.gradle
3+
build/
4+
!gradle/wrapper/gradle-wrapper.jar
5+
!**/src/main/**/build/
6+
!**/src/test/**/build/
7+
8+
### STS ###
9+
.apt_generated
10+
.classpath
11+
.factorypath
12+
.project
13+
.settings
14+
.springBeans
15+
.sts4-cache
16+
bin/
17+
!**/src/main/**/bin/
18+
!**/src/test/**/bin/
19+
20+
### IntelliJ IDEA ###
21+
.idea
22+
*.iws
23+
*.iml
24+
*.ipr
25+
out/
26+
!**/src/main/**/out/
27+
!**/src/test/**/out/
28+
29+
### NetBeans ###
30+
/nbproject/private/
31+
/nbbuild/
32+
/dist/
33+
/nbdist/
34+
/.nb-gradle/
35+
36+
### VS Code ###
37+
.vscode/
38+
39+
### Custom ###
40+
db_dev.mv.db
41+
db_dev.trace.db
42+
.env
43+

backend/build.gradle

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
plugins {
2+
id 'java'
3+
id 'org.springframework.boot' version '3.5.5'
4+
id 'io.spring.dependency-management' version '1.1.7'
5+
}
6+
7+
group = 'com.ai.lawyer'
8+
version = '0.0.1-SNAPSHOT'
9+
description = 'backend'
10+
11+
java {
12+
toolchain {
13+
languageVersion = JavaLanguageVersion.of(21)
14+
}
15+
}
16+
17+
configurations {
18+
compileOnly {
19+
extendsFrom annotationProcessor
20+
}
21+
}
22+
23+
repositories {
24+
mavenCentral()
25+
}
26+
27+
dependencies {
28+
implementation 'org.springframework.boot:spring-boot-starter-cache'
29+
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
30+
implementation 'org.springframework.boot:spring-boot-starter-data-redis'
31+
implementation 'org.springframework.boot:spring-boot-starter-security'
32+
implementation 'org.springframework.boot:spring-boot-starter-validation'
33+
implementation 'org.springframework.boot:spring-boot-starter-web'
34+
implementation("org.springdoc:springdoc-openapi-starter-webmvc-ui:2.8.9")
35+
compileOnly 'org.projectlombok:lombok'
36+
developmentOnly 'org.springframework.boot:spring-boot-devtools'
37+
runtimeOnly 'com.h2database:h2'
38+
runtimeOnly 'org.postgresql:postgresql'
39+
annotationProcessor 'org.projectlombok:lombok'
40+
testImplementation 'org.springframework.boot:spring-boot-starter-test'
41+
testImplementation 'org.springframework.security:spring-security-test'
42+
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
43+
}
44+
45+
tasks.named('test') {
46+
useJUnitPlatform()
47+
}

backend/docker-compose.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
version: '3.8'
2+
3+
services:
4+
postgres:
5+
image: postgres:latest
6+
container_name: postgres
7+
restart: always
8+
environment:
9+
POSTGRES_DB: ${DB_NAME}
10+
POSTGRES_USER: ${DB_USER}
11+
POSTGRES_PASSWORD: ${DB_PASS}
12+
ports:
13+
- "${DB_PORT}:${DB_PORT}"
14+
volumes:
15+
- postgres-data:/var/lib/postgresql/data
16+
# Redis 서비스
17+
redis:
18+
image: redis:latest
19+
container_name: redis
20+
restart: always
21+
ports:
22+
- "${REDIS_PORT}:${REDIS_PORT}"
23+
volumes:
24+
- redis-data:/data
25+
26+
volumes:
27+
postgres-data:
28+
redis-data:
42.7 KB
Binary file not shown.
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
distributionBase=GRADLE_USER_HOME
2+
distributionPath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
4+
networkTimeout=10000
5+
validateDistributionUrl=true
6+
zipStoreBase=GRADLE_USER_HOME
7+
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)