heroku_tasks 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/heroku_tasks/version.rb +1 -1
- data/lib/tasks/deploy.rake +6 -4
- metadata +3 -3
data/lib/heroku_tasks/version.rb
CHANGED
data/lib/tasks/deploy.rake
CHANGED
@@ -21,7 +21,7 @@ namespace :deploy do
|
|
21
21
|
|
22
22
|
namespace :staging do
|
23
23
|
desc "Heroku staging (#{HerokuTasks.staging}) deploy with migration (and copy production db)"
|
24
|
-
task :migrations => [:set_staging_app, :push, :
|
24
|
+
task :migrations => [:set_staging_app, :push, :copy_production_db_to_staging, :migrate, :restart, :tag]
|
25
25
|
desc "Heroku staging (#{HerokuTasks.staging}) rollback"
|
26
26
|
task :rollback => [:set_staging_app, :rollback, :restart]
|
27
27
|
end
|
@@ -74,11 +74,13 @@ namespace :deploy do
|
|
74
74
|
end
|
75
75
|
end
|
76
76
|
|
77
|
-
task :
|
77
|
+
task :copy_production_db_to_staging do
|
78
78
|
timed do
|
79
79
|
puts "\nCopying production database for #{app_and_target} ..."
|
80
|
-
|
81
|
-
|
80
|
+
heroku db:pull postgres://localhost/msv_backup --app mysublime
|
81
|
+
|
82
|
+
system "heroku db:pull postgres://localhost/#{HerokuTasks.production}_backup --app #{HerokuTasks.production}"
|
83
|
+
system "heroku db:push postgres://localhost/#{HerokuTasks.production}_backup --app #{HerokuTasks.staging}"
|
82
84
|
end
|
83
85
|
end
|
84
86
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heroku_tasks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 31
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 2
|
10
|
+
version: 0.1.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Thibaud Guillaume-Gentil
|