I am trying to use Flyway to run migrations for my Grails 3.2.8 application. According to https://flywaydb.org/documentation/plugins/grails one should just need to add a dependency to build.gradle:
dependencies {
compile "org.flywaydb:flyway-core:4.1.2"
}
As I want Flyway to generate my schema I have also edited application.yml to not have domain object generated. If I do not have this setting Grails will generate my tables - not Flyway.
environments:
development:
dataSource:
dbCreate: none
I have also added a migration file to:
grails-app
conf
db
migration
V1__create_tables.sql
I also read here (https://docs.spring.io/spring-boot/docs/current/reference/html/common-application-properties.html) that some extra configuration could done so I added this to application.yml:
flyway:
enabled: true
locations: classpath:grails-app/conf/db/migration
sql-migration-prefix: V
sql-migration-suffix: .sql
I have also tried without any of my added configurations. I seem to be missing something?