liquibase-gradle-plugin
liquibase-gradle-plugin copied to clipboard
Avoiding duplication of properties between spring boot and gradle
I'm not experienced with gradle so forgive me if this is very obvious, but I'm trying to have the plugin use the same configuration as it would when running in spring boot context.
For example, one would have the following properties files:
application.properties <- Properties that are the same across all environments
application-prod.properties <- Some properties overriden here
application-dev.properties <- Some properties overriden here
Let's also say that some of my properties look like this spring.datasource.password=${DATASOURCE_PASSWORD:test_pw}
How can I avoid duplicating all of these properties between gradle and spring? Also, what would be the best way to chose the spring env when running the plugin?
It's essentially the same question as this one on Sackoverflow, but it has no answers.
Yeah, the current approach is overcomplicated. It should be loaded from properties as a plugin for Maven in an ideal world.