Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ansible: skip validations before migration #148

merged 1 commit into from May 3, 2019
Changes from all commits
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.


Just for now

ansible: skip validations before migration

If existing migrations have already been applied, Flyway will by default
validate all of them before migrating.

Our Ansible playbook however only downloads the delta of migrations to
run, not the full history: so if there are existing migrations, the
playbook would fail.

Flyway has a flag ignoreMissingMigrations since 4.1.0, but our binary is
still based on 4.0 and upgrading it is quite hard unfortunately.

Luckily validateOnMigrate skips that validation as well, so it offers a good
workaround for now.

Signed-off-by: Pierre-Alexandre Meyer <>
  • Loading branch information...
pierre committed May 2, 2019
commit a2fe265937e53c6e3c58d20988e8e960c7b5274a
@@ -21,7 +21,7 @@

- block:
- name: run SQL migration
command: "{{ flyway }} -locations=filesystem:{{ migration['dir'] }} -table={{ migration['table'] }} migrate"
command: "{{ flyway }} -locations=filesystem:{{ migration['dir'] }} -table={{ migration['table'] }} -validateOnMigrate=false migrate"
register: java_migrations
ignore_errors: True
tags: migrations
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.