Pass devture_postgres_db_migration_request to com.devture.ansible.role.postgres in a cleaner way

This commit is contained in:
Slavi Pantaleev
2022-11-28 07:44:59 +02:00
parent 910cd9adf0
commit 4b111d05d5
21 changed files with 84 additions and 105 deletions

View File

@ -12,7 +12,10 @@
- when: "matrix_mautrix_discord_sqlite_database_path_local_stat_result.stat.exists | bool"
block:
- ansible.builtin.set_fact:
- ansible.builtin.include_role:
name: galaxy/com.devture.ansible.role.postgres
tasks_from: migrate_db_to_postgres
vars:
devture_postgres_db_migration_request:
src: "{{ matrix_mautrix_discord_sqlite_database_path_local }}"
dst: "{{ matrix_mautrix_discord_database_connection_string }}"
@ -22,10 +25,6 @@
systemd_services_to_stop: ['matrix-mautrix-discord.service']
pgloader_options: ['--with "quote identifiers"']
- ansible.builtin.include_role:
name: galaxy/com.devture.ansible.role.postgres
tasks_from: migrate_db_to_postgres
- ansible.builtin.set_fact:
matrix_mautrix_discord_requires_restart: true