aws-ec2 1.4.7 → 1.4.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ee0ea02658d486e66858c54d3b41e91a70566e51da76bf3d785875e7014df39d
4
- data.tar.gz: ea1c08516e20b2a670b62be2cab5763adcc7f82061cb7da53a25015526741848
3
+ metadata.gz: bfe311c06bd5d34433b91f02cfc04728c124b46cbfe67b54b16e3876daed0320
4
+ data.tar.gz: 577e3e4bcb9241021c6358f1a7977bb846a23073e313a99158bb720cb1a33c6a
5
5
  SHA512:
6
- metadata.gz: 4bf875d2b4fdcebaddd99ece713e57fa6ffed3b3491b394056895e92ede295ae5c5f2ddd3eb8b4f69b886ee989e001f192d30f3c715a3d6bd675ec28d78642ef
7
- data.tar.gz: 6489f81330974a1c23f7d6f7f5c6cb2a3227f27ba97431d5e5c07d080e391528593de3bea338677c433eb4626450f81b7952f69ffe80d487622c1d81660cbd27
6
+ metadata.gz: 3893397e1f298040f246ae5013a6cd2d69c1d721acd6ddad9e4aa0a6a3256862039d5998c48de6c83afdfe27c2bcd98868144addd1fc724214d19da63f94b400
7
+ data.tar.gz: 914c393e55c6212b14111208aba72926c74f0af88bd345554e14aa4deae114540256b287f1ad8404f677cf75672fef18ee5df4366c169b54ed2e20574dde4dae
@@ -3,6 +3,9 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  This project *tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
5
5
 
6
+ ## [1.4.8]
7
+ - show auto-terminate log also in AWS_EC2_CW mode
8
+
6
9
  ## [1.4.7]
7
10
  - add AWS_EC2_CW to show cw tail command
8
11
 
@@ -93,13 +93,19 @@ module AwsEc2
93
93
  region = get_region
94
94
  stream = "#{instance_id}/var/log/cloud-init-output.log"
95
95
  url = "https://#{region}.console.aws.amazon.com/cloudwatch/home?region=#{region}#logEventViewer:group=ec2;stream=#{stream}"
96
- cw_command = "cw tail -f ec2 #{stream}"
96
+ cw_init_log = "cw tail -f ec2 #{stream}"
97
97
  puts "To view instance's cloudwatch logs visit:"
98
98
  puts " #{url}"
99
- puts " #{cw_command}" if ENV['AWS_EC2_CW']
99
+
100
+ puts " #{cw_init_log}" if ENV['AWS_EC2_CW']
101
+ if ENV['AWS_EC2_CW'] && @options[:auto_terminate]
102
+ cw_terminate_log = "cw tail -f ec2 #{instance_id}/var/log/cloud-init-output.log"
103
+ puts " #{cw_terminate_log}"
104
+ end
105
+
100
106
  puts "Note: It takes a little time for the instance to launch and report logs."
101
107
 
102
- paste_command = ENV['AWS_EC2_CW'] ? cw_command : url
108
+ paste_command = ENV['AWS_EC2_CW'] ? cw_init_log : url
103
109
  add_to_clipboard(paste_command)
104
110
  end
105
111
 
@@ -1,3 +1,3 @@
1
1
  module AwsEc2
2
- VERSION = "1.4.7"
2
+ VERSION = "1.4.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-ec2
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.7
4
+ version: 1.4.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tung Nguyen