Skip to content

Commit

Permalink
Fixes #27534 - Add rake task for migrating Dynflow tables
Browse files Browse the repository at this point in the history
(cherry picked from commit 0045bc4)
  • Loading branch information
adamruzicka authored and tbrisker committed Sep 4, 2019
1 parent 6e2ab45 commit 64420e7
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/tasks/dynflow.rake
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,11 @@ END_DESC
task :executor => :environment do
Dynflow::Rails::Daemon.new.run
end

task :migrate => :environment do
world = OpenStruct.new(:config => OpenStruct.new(:queues => {}))
config = Dynflow::Rails::Configuration.new
# Persistence initialization automatically migrates the db
config.send(:initialize_persistence, world)
end
end

0 comments on commit 64420e7

Please sign in to comment.