Skip to content

Commit

Permalink
chore: postgresql 연결 (#93)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sangwook02 committed Oct 10, 2023
1 parent 43605f6 commit 1094ed4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
5 changes: 4 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,14 @@ dependencies {
// aws
implementation 'org.springframework.cloud:spring-cloud-starter-aws:2.2.6.RELEASE'

// postgresql
implementation 'org.postgresql:postgresql:42.6.0'
runtimeOnly 'org.postgresql:postgresql'

//redis
implementation 'org.springframework.boot:spring-boot-starter-data-redis'

compileOnly 'org.projectlombok:lombok'
runtimeOnly 'com.h2database:h2'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}
Expand Down
10 changes: 4 additions & 6 deletions src/main/resources/application.properties
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
# h2 database
spring.datasource.driver-class-name=org.h2.Driver
spring.datasource.url=jdbc:h2:mem:testdb
spring.datasource.username=sa
spring.h2.console.enabled=true
# jpa
spring.jpa.defer-datasource-initialization=true
spring.jpa.database=postgresql
spring.jpa.properties.hibernate.format_sql=true
spring.jpa.show-sql=true
spring.jpa.properties.hibernate.use_sql_comments=true
spring.jpa.hibernate.ddl-auto=update
spring.jpa.defer-datasource-initialization=true

#security
spring.profiles.include=security
Expand Down

0 comments on commit 1094ed4

Please sign in to comment.