ciinabox-ecs 0.2.12.alpha.1531204956 → 0.2.12.alpha.1531450459

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -0
  3. data/Rakefile +27 -0
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8ca03999eb345f623b24c90a729b96044381b8ed583ec3768edcac55d371794b
4
- data.tar.gz: 68cb95107df2fcea8d92de1b71ef85afaa86122c457489a983053373d7160171
3
+ metadata.gz: 6690995b43e637fc73e07abed80ac5058564ac25d83ffc0f349411d7d6f43dba
4
+ data.tar.gz: 9c13b508bb15d41714cf8166adf86be033de4f327e4523f7740036678682aec9
5
5
  SHA512:
6
- metadata.gz: 0df8ae397f57fdccb47f713a2059d18d24c49d9a803822713d4afe71fc88220d2c33368d5f35adcdc706fe8a3749319935acc8fcb55562b57509745a91ab7a68
7
- data.tar.gz: ae5638fd976b278d00585d5d9cff1b3a99b849e14261f3d366e1852f7e4a023a036dd02e643aed4c54d64f194653d05526bbe9961f5fd5b88ad70bf6faaf1b6c
6
+ metadata.gz: 548fe11c520f16b9548a3acb596a582acbb5c536460b2266ad0e70342b86ef6b3924e9de3b8925f2e8c1a7c71074a8344fe1fe8218eb2a66f69efe7ad84e771a
7
+ data.tar.gz: 6401bd0fd92b1acd67b0cccafde1449e5141fb93a9c84f29f64c95d30ebb3d61e2e5c83e1f05c7545fa6b212fb5414323e3441d5b0e3c3361e097b1ca4909744
data/README.md CHANGED
@@ -51,6 +51,7 @@ up |Turn on your ciinabox environment
51
51
  update |Updates the ciinabox environment
52
52
  update_cert_to_acm |Replace previously auto-generated IAM certificate with auto-validated ACM certificate (if one exists)
53
53
  upload_server_cert |Uploads SSL server certs for ciinabox
54
+ watch |Monitors status of the active ciinabox until failed or successful
54
55
 
55
56
  ```
56
57
 
data/Rakefile CHANGED
@@ -231,6 +231,33 @@ namespace :ciinabox do
231
231
  end
232
232
  end
233
233
 
234
+ desc('Watches the status of the active ciinabox')
235
+ task :watch do
236
+ last_status = ""
237
+ while true
238
+ check_active_ciinabox(config)
239
+ status, result = aws_execute(config, ['cloudformation', 'describe-stacks', "--stack-name #{stack_name}", '--query "Stacks[0].StackStatus"', '--out text'])
240
+ if status != 0
241
+ puts "fail to get status for #{config['ciinabox_name']}...has it been created?"
242
+ exit 1
243
+ end
244
+ output = result.chop!
245
+ next if last_status == output
246
+ if output == 'CREATE_COMPLETE' || output == 'UPDATE_COMPLETE'
247
+ puts Time.now.strftime("%Y/%m/%d %H:%M") + " #{config['ciinabox_name']} ciinabox is alive!!!!"
248
+ display_ecs_ip_address config
249
+ exit 0
250
+ elsif output == 'ROLLBACK_COMPLETE'
251
+ puts Time.now.strftime("%Y/%m/%d %H:%M") + " #{config['ciinabox_name']} ciinabox has failed and rolled back"
252
+ exit 1
253
+ else
254
+ puts Time.now.strftime("%Y/%m/%d %H:%M") + " #{config['ciinabox_name']} ciinabox is in state: #{output}"
255
+ end
256
+ last_status = output
257
+ sleep(4)
258
+ end
259
+ end
260
+
234
261
  desc('Create self-signed SSL certs for use with ciinabox')
235
262
  task :create_server_cert do
236
263
  check_active_ciinabox(config)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ciinabox-ecs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.12.alpha.1531204956
4
+ version: 0.2.12.alpha.1531450459
5
5
  platform: ruby
6
6
  authors:
7
7
  - Base2Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-10 00:00:00.000000000 Z
11
+ date: 2018-07-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake