Skip to content

Commit

Permalink
Only migrate the primary database in prepare_all_with_data
Browse files Browse the repository at this point in the history
Co-authored-by: Maple Ong <[email protected]>
  • Loading branch information
Floppy and wildmaples committed Jun 20, 2024
1 parent 880d94e commit 9f3e76a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/data_migrate/database_tasks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ def self.prepare_all_with_data
seed = false

each_current_configuration(env) do |db_config|
next unless db_config.primary?

with_temporary_pool(db_config) do
begin
database_initialized = migration_connection.schema_migration.table_exists?
Expand Down

0 comments on commit 9f3e76a

Please sign in to comment.