recipiez 0.6.12 → 0.6.13

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.
@@ -1,3 +1,3 @@
1
1
  module Recipiez
2
- VERSION = '0.6.12'
2
+ VERSION = '0.6.13'
3
3
  end
@@ -90,35 +90,7 @@ namespace :recipiez do
90
90
 
91
91
  desc "Dump database, copy it across and restore locally."
92
92
  task :pull do
93
- set_variables_from_yaml
94
- archive = generate_archive(application)
95
- filename = get_filename(application)
96
- cmd = "mysqldump --opt --skip-add-locks -u #{db_user} "
97
- cmd += " -h #{db_host} " if exists?('db_host')
98
- cmd += " -p#{db_password} "
99
- cmd += "#{database_to_dump} > #{archive}"
100
- result = run(cmd)
101
-
102
- cmd = "rsync -av -e \"ssh -p #{ssh_options[:port]} #{get_identities}\" #{user}@#{roles[:db].servers.first}:#{archive} #{dump_dir}#{filename}"
103
- puts "running #{cmd}"
104
- result = system(cmd)
105
- puts result
106
- run "rm #{archive}"
107
-
108
- puts "Restoring db"
109
- begin
110
- `mysqladmin -u#{db_local_user} -p#{db_local_password} --force drop #{db_dev}`
111
- rescue
112
- # do nothing
113
- end
114
- `mysqladmin -u#{db_local_user} -p#{db_local_password} --force create #{db_dev}`
115
- `cat #{dump_dir}#{get_filename(application)} | mysql -u#{db_local_user} -p#{db_local_password} #{db_dev}`
116
- puts "All done!"
117
- end
118
-
119
- desc "Dump alternate database, copy it across and restore it locally"
120
- task :pull_alternate do
121
- set_variables_from_yaml(alternate_yaml_env)
93
+ set_variables_from_yaml(yaml_env)
122
94
  archive = generate_archive(application)
123
95
  filename = get_filename(application)
124
96
  cmd = "mysqldump --opt --skip-add-locks -u #{db_user} "
@@ -144,7 +116,7 @@ namespace :recipiez do
144
116
  puts "All done!"
145
117
  end
146
118
 
147
- desc "Push up the db"
119
+ desc "Push up the db"
148
120
  task :push do
149
121
  set_variables_from_yaml
150
122
  filename = get_filename(application)
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 6
8
- - 12
9
- version: 0.6.12
8
+ - 13
9
+ version: 0.6.13
10
10
  platform: ruby
11
11
  authors:
12
12
  - Alastair Brunton