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

Commit

Permalink
Merge pull request #125 from Mini-Team-6/feature/#124-apply-flyway
Browse files Browse the repository at this point in the history
Feat: flyway 적용
  • Loading branch information
laigasus authored Dec 15, 2023
2 parents 11ed3ae + c134c64 commit 8f6f5e6
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 1 deletion.
21 changes: 21 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'org.flywaydb:flyway-mysql:+'
}
}

plugins {
id 'java'
id 'org.springframework.boot' version '3.1.5'
id 'io.spring.dependency-management' version '1.1.3'
id "org.flywaydb.flyway" version '+'
}

group = 'ybe.mini'
Expand Down Expand Up @@ -41,6 +51,10 @@ dependencies {
annotationProcessor "jakarta.annotation:jakarta.annotation-api"
annotationProcessor "jakarta.persistence:jakarta.persistence-api"

//flyway
implementation 'org.flywaydb:flyway-core'
implementation 'org.flywaydb:flyway-mysql'

// validation
implementation 'org.springframework.boot:spring-boot-starter-validation'

Expand Down Expand Up @@ -79,4 +93,11 @@ tasks.withType(JavaCompile).configureEach {

clean.doLast {
file(querydslDir).deleteDir()
}

flyway {
url = "jdbc:mysql://localhost:3303/travel"
user = "root"
password = "root"
cleanDisabled = false
}
9 changes: 8 additions & 1 deletion src/main/resources/application-core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,11 @@ spring:
enabled: true #표준 예외 폼 사용
web:
resources:
add-mappings: false # 404오류 에 대해 리소스에서 접근하지 않고 예외로 던지기
add-mappings: false # 404오류 에 대해 리소스에서 접근하지 않고 예외로 던지기

flyway:
enabled: false
baseline-on-migrate: false
encoding: UTF-8
outOfOrder: true
locations: classpath:db/migration
Empty file.

0 comments on commit 8f6f5e6

Please sign in to comment.