How to override the database user that the flyway configuration uses for migration? #29556
Unanswered
ChrisAtFremtind
asked this question in
Q&A
Replies: 2 comments 3 replies
-
/cc @cristhiank, @gastaldi, @geoand, @gsmet |
Beta Was this translation helpful? Give feedback.
0 replies
-
There is an issue requesting this feature here: |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Is there a way to configure flyway to use a different datasource other than the default one?
From the guide of setting up flyway to work with multiple datasources the guide describes using named datasources, but this is to separate the schemas / concern for each datasource, but I can’t see a any configuration properties or examples where the datasource that flyway uses are changed / overridden, it seems it can only implicitly use the same user as the configured named datasource.
The guide contains this:
What I wished was available was something like this:
*Properties which does not exist.
I have thought out some ways to make this work is
The application user has only limited access to the database as a security measure.
As an example to how this is achieved in Spring with the same configuration above:
With spring's integration to flyway you can explicitly set the desired user that flyway should use to migrate. Is there any plans to make this available as configuration options? Or is there another way to make this work which i don’t see?
Beta Was this translation helpful? Give feedback.
All reactions