Skip to content

Commit fcc6463

Browse files
Add flyway dependency and config. Move db init sql to migration
1 parent e86ed66 commit fcc6463

4 files changed

Lines changed: 14 additions & 0 deletions

File tree

pom.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -558,6 +558,14 @@
558558
<artifactId>translate</artifactId>
559559
<version>2.40.15</version>
560560
</dependency>
561+
<dependency>
562+
<groupId>org.flywaydb</groupId>
563+
<artifactId>flyway-core</artifactId>
564+
</dependency>
565+
<dependency>
566+
<groupId>org.flywaydb</groupId>
567+
<artifactId>flyway-mysql</artifactId>
568+
</dependency>
561569
</dependencies>
562570
<properties>
563571
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

src/main/resources/application-dockerdev-sample.properties

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ server.tomcat.max-http-form-post-size=100MB
1717
spring.servlet.multipart.max-file-size=100MB
1818
spring.servlet.multipart.max-request-size=100MB
1919

20+
spring.devtools.restart.exclude=db/migration/**
21+
2022
########## WISE Properties ##########
2123

2224
# This section is for portal definitions
@@ -97,6 +99,8 @@ spring.redis.pool.max.total=128
9799
#spring.session.redis.flush-mode=on-save # Sessions flush mode.
98100
#spring.session.redis.namespace=spring:session # Namespace for keys used to store sessions.
99101

102+
spring.flyway.baseline-on-migrate=true
103+
100104
######### sendmail properties ##########
101105

102106
# This section defines the settings that the portal will use to send mail.

src/main/resources/application_sample.properties

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,8 @@ spring.redis.pool.max.total=128
9797
#spring.session.redis.flush-mode=on-save # Sessions flush mode.
9898
#spring.session.redis.namespace=spring:session # Namespace for keys used to store sessions.
9999

100+
spring.flyway.baseline-on-migrate=true
101+
100102
######### sendmail properties ##########
101103

102104
# This section defines the settings that the portal will use to send mail.
File renamed without changes.

0 commit comments

Comments
 (0)