heroku_feature_deployments 0.7.2 → 0.7.3
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.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 565006a3468bfa069f7ae4e866184bb4d1f5f6dc
|
4
|
+
data.tar.gz: 23a703a9d626f2d819785ac8e671804d9fada1ab
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec267757f291cdf62d448445cbc2a0025aa5697d9ca7ec5851f348a10601b37c11ab662a122c647b0c9e8bb5f99ca7bdc3511b5be5b37032e6eac46c0c1fa56b
|
7
|
+
data.tar.gz: 56dc364352fe1f7556a0e108e05329a195c7fb299660d440bdb3d47335bb7e6aba4fed40985d79151548c8f8b2746521d938c7e8fd1a30d3ece4e06172302be0
|
@@ -127,8 +127,12 @@ module HerokuFeatureDeployments
|
|
127
127
|
end
|
128
128
|
|
129
129
|
def create_db
|
130
|
-
config.logger.info "Creating
|
131
|
-
heroku.post_ps(@full_app_name, 'rake db:create db:migrate
|
130
|
+
config.logger.info "Creating and migrating the database"
|
131
|
+
heroku.post_ps(@full_app_name, 'rake db:create db:migrate')
|
132
|
+
wait_for_process_to_finish 'rake db:create db:migrate'
|
133
|
+
config.logger.info 'Seeding the database'
|
134
|
+
heroku.post_ps(@full_app_name, 'rake db:seed')
|
135
|
+
wait_for_process_to_finish 'rake db:seed'
|
132
136
|
end
|
133
137
|
|
134
138
|
def migrate_db
|
@@ -220,5 +224,17 @@ module HerokuFeatureDeployments
|
|
220
224
|
config.logger.info "Running command: #{command}"
|
221
225
|
system command
|
222
226
|
end
|
227
|
+
|
228
|
+
def wait_for_process_to_finish(command)
|
229
|
+
config.logger.info "waiting for #{command} to finish"
|
230
|
+
|
231
|
+
while true
|
232
|
+
break unless running_process_names.
|
233
|
+
any? { |n| n.match(/#{Regexp.escape(command)}/i) }
|
234
|
+
print '.'
|
235
|
+
sleep 5
|
236
|
+
end
|
237
|
+
puts
|
238
|
+
end
|
223
239
|
end
|
224
240
|
end
|