cloud66_agent 1.0.9 → 1.0.10

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.
@@ -7,7 +7,7 @@ Gem::Specification.new do |gem|
7
7
  gem.name = "cloud66_agent"
8
8
  gem.version = Cloud66::Utils::Version.current
9
9
  gem.platform = Gem::Platform::RUBY
10
- gem.date = '2013-05-07'
10
+ gem.date = '2013-07-10'
11
11
  gem.authors = ["Cloud 66"]
12
12
  gem.email = ['hello@cloud66.com']
13
13
  gem.description = "See https://www.cloud66.com for more info"
@@ -13,7 +13,7 @@ module Cloud66
13
13
  # Defines the minor version
14
14
  # PATCH:
15
15
  # Defines the patch version
16
- MAJOR, MINOR, PATCH = 1, 0, 9
16
+ MAJOR, MINOR, PATCH = 1, 0, 10
17
17
 
18
18
  #ie. PRERELEASE_MODIFIER = 'beta1'
19
19
  PRERELEASE_MODIFIER = nil
@@ -43,8 +43,9 @@ module Cloud66
43
43
  end
44
44
 
45
45
  def self.is_aws?
46
- hash = parse_data(`facter ec2_ami_id placeholder`)
47
- return hash.has_key?('ec2_ami_id')
46
+ # 6 seconds to find out if this is a AWS image or not!
47
+ instance = `/usr/bin/curl --connect-timeout 6 -s http://169.254.169.254/latest/meta-data/instance-id` rescue nil
48
+ return !instance.nil? && !instance.empty?
48
49
  end
49
50
 
50
51
  private
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloud66_agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.9
4
+ version: 1.0.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-05-07 00:00:00.000000000 Z
12
+ date: 2013-07-10 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: httparty