fauxhai 4.1.0 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (127) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +3 -2
  3. data/CHANGELOG.md +71 -12
  4. data/CONTRIBUTING.md +32 -20
  5. data/PLATFORMS.md +13 -73
  6. data/README.md +4 -4
  7. data/Rakefile +5 -1
  8. data/fauxhai.gemspec +3 -3
  9. data/lib/fauxhai/fetcher.rb +1 -1
  10. data/lib/fauxhai/mocker.rb +19 -17
  11. data/lib/fauxhai/platforms/amazon/2012.09.json +526 -178
  12. data/lib/fauxhai/platforms/amazon/2013.09.json +561 -235
  13. data/lib/fauxhai/platforms/amazon/2014.03.json +586 -291
  14. data/lib/fauxhai/platforms/amazon/2014.09.json +552 -218
  15. data/lib/fauxhai/platforms/amazon/2015.03.json +576 -222
  16. data/lib/fauxhai/platforms/amazon/2015.09.json +542 -238
  17. data/lib/fauxhai/platforms/amazon/2016.03.json +552 -246
  18. data/lib/fauxhai/platforms/amazon/2016.09.json +539 -237
  19. data/lib/fauxhai/platforms/amazon/2017.03.json +667 -0
  20. data/lib/fauxhai/platforms/arch/4.10.13-1-ARCH.json +1674 -0
  21. data/lib/fauxhai/platforms/arch/4.5.4-1-ARCH.json +2 -1
  22. data/lib/fauxhai/platforms/arch/4.9.11-1-ARCH.json +1 -0
  23. data/lib/fauxhai/platforms/centos/5.0.json +1 -0
  24. data/lib/fauxhai/platforms/centos/5.1.json +1 -0
  25. data/lib/fauxhai/platforms/centos/5.10.json +4536 -496
  26. data/lib/fauxhai/platforms/centos/5.11.json +4485 -318
  27. data/lib/fauxhai/platforms/centos/5.2.json +1 -0
  28. data/lib/fauxhai/platforms/centos/5.3.json +1 -0
  29. data/lib/fauxhai/platforms/centos/5.4.json +1 -0
  30. data/lib/fauxhai/platforms/centos/5.5.json +1 -0
  31. data/lib/fauxhai/platforms/centos/5.6.json +1 -0
  32. data/lib/fauxhai/platforms/centos/5.7.json +1 -0
  33. data/lib/fauxhai/platforms/centos/5.8.json +1 -0
  34. data/lib/fauxhai/platforms/centos/5.9.json +1 -0
  35. data/lib/fauxhai/platforms/centos/6.0.json +1 -0
  36. data/lib/fauxhai/platforms/centos/6.1.json +1 -0
  37. data/lib/fauxhai/platforms/centos/6.2.json +1 -0
  38. data/lib/fauxhai/platforms/centos/6.3.json +1 -0
  39. data/lib/fauxhai/platforms/centos/6.4.json +1 -0
  40. data/lib/fauxhai/platforms/centos/6.5.json +1 -0
  41. data/lib/fauxhai/platforms/centos/6.6.json +1 -0
  42. data/lib/fauxhai/platforms/centos/6.8.json +2278 -422
  43. data/lib/fauxhai/platforms/centos/6.9.json +5910 -0
  44. data/lib/fauxhai/platforms/centos/7.0.1406.json +2 -1
  45. data/lib/fauxhai/platforms/centos/7.0.json +2 -1
  46. data/lib/fauxhai/platforms/centos/7.1.1503.json +2 -1
  47. data/lib/fauxhai/platforms/centos/7.2.1511.json +3620 -547
  48. data/lib/fauxhai/platforms/centos/7.3.1611.json +3781 -561
  49. data/lib/fauxhai/platforms/clearos/7.0.json +1985 -0
  50. data/lib/fauxhai/platforms/debian/7.0.json +1 -0
  51. data/lib/fauxhai/platforms/debian/7.1.json +1 -0
  52. data/lib/fauxhai/platforms/debian/7.10.json +3568 -522
  53. data/lib/fauxhai/platforms/debian/7.11.json +3340 -311
  54. data/lib/fauxhai/platforms/debian/7.2.json +1 -0
  55. data/lib/fauxhai/platforms/debian/7.4.json +1 -0
  56. data/lib/fauxhai/platforms/debian/7.5.json +1 -0
  57. data/lib/fauxhai/platforms/debian/7.6.json +1 -0
  58. data/lib/fauxhai/platforms/debian/7.7.json +1 -0
  59. data/lib/fauxhai/platforms/debian/7.8.json +1 -0
  60. data/lib/fauxhai/platforms/debian/7.9.json +1 -0
  61. data/lib/fauxhai/platforms/debian/8.0.json +1 -0
  62. data/lib/fauxhai/platforms/debian/8.1.json +2 -1
  63. data/lib/fauxhai/platforms/debian/8.2.json +2 -1
  64. data/lib/fauxhai/platforms/debian/8.4.json +2 -1
  65. data/lib/fauxhai/platforms/debian/8.5.json +1 -0
  66. data/lib/fauxhai/platforms/debian/8.6.json +1 -0
  67. data/lib/fauxhai/platforms/debian/8.7.json +3398 -544
  68. data/lib/fauxhai/platforms/debian/8.8.json +3620 -0
  69. data/lib/fauxhai/platforms/fedora/21.json +2 -1
  70. data/lib/fauxhai/platforms/fedora/22.json +2 -1
  71. data/lib/fauxhai/platforms/fedora/23.json +2 -1
  72. data/lib/fauxhai/platforms/fedora/24.json +5120 -668
  73. data/lib/fauxhai/platforms/fedora/25.json +5140 -560
  74. data/lib/fauxhai/platforms/freebsd/10.1.json +2 -1
  75. data/lib/fauxhai/platforms/freebsd/10.2.json +2 -1
  76. data/lib/fauxhai/platforms/freebsd/10.3.json +276 -137
  77. data/lib/fauxhai/platforms/freebsd/11.0.json +270 -137
  78. data/lib/fauxhai/platforms/freebsd/9.3.json +2 -1
  79. data/lib/fauxhai/platforms/linuxmint/18.1.json +10773 -0
  80. data/lib/fauxhai/platforms/mac_os_x/10.10.json +618 -542
  81. data/lib/fauxhai/platforms/mac_os_x/10.11.1.json +1 -0
  82. data/lib/fauxhai/platforms/mac_os_x/10.11.json +982 -0
  83. data/lib/fauxhai/platforms/mac_os_x/10.12.json +658 -645
  84. data/lib/fauxhai/platforms/mac_os_x/10.9.2.json +1 -0
  85. data/lib/fauxhai/platforms/omnios/151014.json +2 -1
  86. data/lib/fauxhai/platforms/opensuse/12.3.json +2 -1
  87. data/lib/fauxhai/platforms/opensuse/13.1.json +1 -0
  88. data/lib/fauxhai/platforms/opensuse/13.2.json +4667 -558
  89. data/lib/fauxhai/platforms/opensuse/42.1.json +5544 -461
  90. data/lib/fauxhai/platforms/opensuse/42.2.json +7674 -545
  91. data/lib/fauxhai/platforms/oracle/5.8.json +1 -0
  92. data/lib/fauxhai/platforms/oracle/6.5.json +1 -0
  93. data/lib/fauxhai/platforms/oracle/6.6.json +1 -0
  94. data/lib/fauxhai/platforms/oracle/7.0.json +1 -0
  95. data/lib/fauxhai/platforms/oracle/7.1.json +1 -0
  96. data/lib/fauxhai/platforms/redhat/5.6.json +2 -1
  97. data/lib/fauxhai/platforms/redhat/5.7.json +2 -1
  98. data/lib/fauxhai/platforms/redhat/5.8.json +2 -1
  99. data/lib/fauxhai/platforms/redhat/6.0.json +2 -1
  100. data/lib/fauxhai/platforms/redhat/6.1.json +2 -1
  101. data/lib/fauxhai/platforms/redhat/6.2.json +2 -1
  102. data/lib/fauxhai/platforms/redhat/6.3.json +2 -1
  103. data/lib/fauxhai/platforms/redhat/6.4.json +2 -1
  104. data/lib/fauxhai/platforms/redhat/6.5.json +2 -1
  105. data/lib/fauxhai/platforms/redhat/6.6.json +1 -0
  106. data/lib/fauxhai/platforms/redhat/7.0.json +1 -0
  107. data/lib/fauxhai/platforms/redhat/7.1.json +1 -0
  108. data/lib/fauxhai/platforms/smartos/joyent_20130111T180733Z.json +2 -1
  109. data/lib/fauxhai/platforms/solaris2/5.11.json +10884 -3268
  110. data/lib/fauxhai/platforms/suse/11.3.json +2 -1
  111. data/lib/fauxhai/platforms/suse/12.0.json +1 -0
  112. data/lib/fauxhai/platforms/ubuntu/12.04.json +2 -1
  113. data/lib/fauxhai/platforms/ubuntu/14.04.json +2800 -272
  114. data/lib/fauxhai/platforms/ubuntu/15.04.json +2 -1
  115. data/lib/fauxhai/platforms/ubuntu/15.10.json +2 -1
  116. data/lib/fauxhai/platforms/ubuntu/16.04.json +3487 -541
  117. data/lib/fauxhai/platforms/windows/10.json +119 -82
  118. data/lib/fauxhai/platforms/windows/2003R2.json +1 -0
  119. data/lib/fauxhai/platforms/windows/2008R2.json +156 -5734
  120. data/lib/fauxhai/platforms/windows/2012R2.json +157 -3592
  121. data/lib/fauxhai/platforms/windows/7.json +116 -77
  122. data/lib/fauxhai/platforms/windows/8.1.json +100 -98
  123. data/lib/fauxhai/platforms/windows/8.json +1 -0
  124. data/lib/fauxhai/runner.rb +6 -3
  125. data/lib/fauxhai/runner/default.rb +133 -67
  126. data/lib/fauxhai/version.rb +1 -1
  127. metadata +15 -8
@@ -45,7 +45,7 @@ module Fauxhai
45
45
  end
46
46
 
47
47
  def cache_file
48
- File.expand_path( File.join(Fauxhai.root, 'tmp', cache_key) )
48
+ File.expand_path(File.join(Fauxhai.root, 'tmp', cache_key))
49
49
  end
50
50
 
51
51
  def force_cache_miss?
@@ -5,10 +5,10 @@ require 'open-uri'
5
5
  module Fauxhai
6
6
  class Mocker
7
7
  # The base URL for the GitHub project (raw)
8
- RAW_BASE = 'https://raw.githubusercontent.com/customink/fauxhai/master'
8
+ RAW_BASE = 'https://raw.githubusercontent.com/chefspec/fauxhai/master'.freeze
9
9
 
10
10
  # A message about where to find a list of platforms
11
- PLATFORM_LIST_MESSAGE = "A list of available platforms is available at https://github.com/customink/fauxhai/blob/master/PLATFORMS.md".freeze
11
+ PLATFORM_LIST_MESSAGE = 'A list of available platforms is available at https://github.com/chefspec/fauxhai/blob/master/PLATFORMS.md'.freeze
12
12
 
13
13
  # @return [Hash] The raw ohai data for the given Mock
14
14
  attr_reader :data
@@ -31,15 +31,6 @@ module Fauxhai
31
31
  @data = fauxhai_data
32
32
  yield(@data) if block_given?
33
33
 
34
- if defined?(::ChefSpec) && ::ChefSpec::VERSION <= '0.9.0'
35
- data = @data
36
- ::ChefSpec::ChefRunner.send :define_method, :fake_ohai do |ohai|
37
- data.each_pair do |attribute, value|
38
- ohai[attribute] = value
39
- end
40
- end
41
- end
42
-
43
34
  @data
44
35
  end
45
36
 
@@ -59,14 +50,14 @@ module Fauxhai
59
50
  end
60
51
 
61
52
  if File.exist?(filepath)
62
- JSON.parse( File.read(filepath) )
63
- elsif !@options[:github_fetching]
53
+ parse_and_validate(File.read(filepath))
54
+ elsif @options[:github_fetching]
64
55
  # Try loading from github (in case someone submitted a PR with a new file, but we haven't
65
56
  # yet updated the gem version). Cache the response locally so it's faster next time.
66
57
  begin
67
58
  response = open("#{RAW_BASE}/lib/fauxhai/platforms/#{platform}/#{version}.json")
68
59
  rescue OpenURI::HTTPError
69
- raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' in any of the sources! #{PLATFORM_LIST_MESSAGE}")
60
+ raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' on the local disk and an HTTP error was encountered when fetching from Github. #{PLATFORM_LIST_MESSAGE}")
70
61
  end
71
62
 
72
63
  if response.status.first.to_i == 200
@@ -75,16 +66,27 @@ module Fauxhai
75
66
  FileUtils.mkdir_p(path.dirname)
76
67
 
77
68
  File.open(filepath, 'w') { |f| f.write(response_body) }
78
- return JSON.parse(response_body)
69
+ return parse_and_validate(response_body)
79
70
  else
80
- raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' in any of the sources! #{PLATFORM_LIST_MESSAGE}")
71
+ raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' on the local disk and an Github fetching returned http error code #{response.status.first.to_i}! #{PLATFORM_LIST_MESSAGE}")
81
72
  end
82
73
  else
83
- raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' in any of the sources!")
74
+ raise Fauxhai::Exception::InvalidPlatform.new("Could not find platform '#{platform}/#{version}' on the local disk and Github fetching is disabled! #{PLATFORM_LIST_MESSAGE}")
84
75
  end
85
76
  end.call
86
77
  end
87
78
 
79
+ # As major releases of Ohai ship it's difficult and sometimes impossible
80
+ # to regenerate all fauxhai data. This allows us to deprecate old releases
81
+ # and eventually remove them while giving end users ample warning.
82
+ def parse_and_validate(unparsed_data)
83
+ parsed_data = JSON.parse(unparsed_data)
84
+ if parsed_data['deprecated']
85
+ STDERR.puts "WARNING: Fauxhai platform data for #{parsed_data['platform']} #{parsed_data['platform_version']} is deprecated and will be removed from a future release. #{PLATFORM_LIST_MESSAGE}"
86
+ end
87
+ parsed_data
88
+ end
89
+
88
90
  def platform
89
91
  @options[:platform] ||= begin
90
92
  STDERR.puts "WARNING: you must specify a 'platform' and 'version' to your ChefSpec Runner and/or Fauxhai constructor, in the future omitting these will become a hard error. #{PLATFORM_LIST_MESSAGE}"
@@ -1,169 +1,108 @@
1
1
  {
2
- "kernel": {
3
- "name": "Linux",
4
- "release": "3.2.38-5.48.amzn1.x86_64",
5
- "version": "#1 SMP Wed Feb 13 01:07:25 UTC 2013",
6
- "machine": "x86_64",
7
- "processor": "x86_64",
8
- "os": "GNU/Linux",
9
- "modules": {
10
- "ipv6": {
11
- "size": "317603",
12
- "refcount": "10"
13
- },
14
- "binfmt_misc": {
15
- "size": "7695",
16
- "refcount": "1"
17
- },
18
- "dm_mod": {
19
- "size": "75314",
20
- "refcount": "0"
21
- },
22
- "scsi_mod": {
23
- "size": "199417",
24
- "refcount": "0"
25
- },
26
- "ext4": {
27
- "size": "456134",
28
- "refcount": "1"
29
- },
30
- "mbcache": {
31
- "size": "7270",
32
- "refcount": "1"
33
- },
34
- "jbd2": {
35
- "size": "86039",
36
- "refcount": "1"
37
- },
38
- "crc16": {
39
- "size": "1557",
40
- "refcount": "1"
41
- }
42
- }
43
- },
44
- "os": "linux",
45
- "os_version": "3.2.38-5.48.amzn1.x86_64",
46
- "lsb": {
47
- },
48
- "platform": "amazon",
49
- "platform_version": "2012.09",
50
- "platform_family": "rhel",
51
- "dmi": {
52
- },
53
- "root_group": "root",
54
- "command": {
55
- "ps": "ps -ef"
56
- },
57
- "filesystem": {
58
- "/dev/xvda1": {
59
- "kb_size": "2064208",
60
- "kb_used": "881284",
61
- "kb_available": "1161964",
62
- "percent_used": "44%",
63
- "mount": "/",
64
- "total_inodes": "131072",
65
- "inodes_used": "35565",
66
- "inodes_available": "95507",
67
- "inodes_percent_used": "28%",
68
- "fs_type": "ext4",
69
- "mount_options": [
70
- "rw",
71
- "noatime"
72
- ]
2
+ "block_device": {
3
+ "loop0": {
4
+ "size": "0",
5
+ "removable": "0",
6
+ "rotational": "1",
7
+ "physical_block_size": "0",
8
+ "logical_block_size": "512"
73
9
  },
74
- "tmpfs": {
75
- "kb_size": "304328",
76
- "kb_used": "0",
77
- "kb_available": "304328",
78
- "percent_used": "0%",
79
- "mount": "/dev/shm",
80
- "total_inodes": "76082",
81
- "inodes_used": "1",
82
- "inodes_available": "76081",
83
- "inodes_percent_used": "1%",
84
- "fs_type": "tmpfs",
85
- "mount_options": [
86
- "rw"
87
- ]
10
+ "loop1": {
11
+ "size": "0",
12
+ "removable": "0",
13
+ "rotational": "1",
14
+ "physical_block_size": "0",
15
+ "logical_block_size": "512"
88
16
  },
89
- "proc": {
90
- "mount": "/proc",
91
- "fs_type": "proc",
92
- "mount_options": [
93
- "rw"
94
- ]
17
+ "loop2": {
18
+ "size": "0",
19
+ "removable": "0",
20
+ "rotational": "1",
21
+ "physical_block_size": "0",
22
+ "logical_block_size": "512"
95
23
  },
96
- "sysfs": {
97
- "mount": "/sys",
98
- "fs_type": "sysfs",
99
- "mount_options": [
100
- "rw"
101
- ]
24
+ "loop3": {
25
+ "size": "0",
26
+ "removable": "0",
27
+ "rotational": "1",
28
+ "physical_block_size": "0",
29
+ "logical_block_size": "512"
102
30
  },
103
- "devpts": {
104
- "mount": "/dev/pts",
105
- "fs_type": "devpts",
106
- "mount_options": [
107
- "rw",
108
- "gid=5",
109
- "mode=620"
110
- ]
31
+ "loop4": {
32
+ "size": "0",
33
+ "removable": "0",
34
+ "rotational": "1",
35
+ "physical_block_size": "0",
36
+ "logical_block_size": "512"
111
37
  },
112
- "none": {
113
- "mount": "/proc/sys/fs/binfmt_misc",
114
- "fs_type": "binfmt_misc",
115
- "mount_options": [
116
- "rw"
117
- ]
38
+ "loop5": {
39
+ "size": "0",
40
+ "removable": "0",
41
+ "rotational": "1",
42
+ "physical_block_size": "0",
43
+ "logical_block_size": "512"
118
44
  },
119
- "rootfs": {
120
- "mount": "/",
121
- "fs_type": "rootfs",
122
- "mount_options": [
123
- "rw"
124
- ]
45
+ "loop6": {
46
+ "size": "0",
47
+ "removable": "0",
48
+ "rotational": "1",
49
+ "physical_block_size": "0",
50
+ "logical_block_size": "512"
125
51
  },
126
- "devtmpfs": {
127
- "mount": "/dev",
128
- "fs_type": "devtmpfs",
129
- "mount_options": [
130
- "rw",
131
- "relatime",
132
- "size=296148k",
133
- "nr_inodes=74037",
134
- "mode=755"
135
- ]
136
- }
137
- },
138
- "ohai_time": 1458950465.4448612,
139
- "init_package": "init",
140
- "languages": {
141
- "ruby": {
142
- "bin_dir": "/usr/local/bin",
143
- "gem_bin": "/usr/local/bin/gem",
144
- "gems_dir": "/usr/local/gems",
145
- "ruby_bin": "/usr/local/bin/ruby"
52
+ "loop7": {
53
+ "size": "0",
54
+ "removable": "0",
55
+ "rotational": "1",
56
+ "physical_block_size": "0",
57
+ "logical_block_size": "512"
146
58
  },
147
- "powershell": null
59
+ "xvda1": {
60
+ "size": "4194304",
61
+ "removable": "0",
62
+ "rotational": "0",
63
+ "physical_block_size": "512",
64
+ "logical_block_size": "512"
65
+ }
148
66
  },
149
67
  "chef_packages": {
150
68
  "chef": {
151
- "version": "12.8.1",
152
- "chef_root": "/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.8.1/lib"
69
+ "version": "13.0.118",
70
+ "chef_root": "/opt/chef/embedded/lib/ruby/gems/2.4.0/gems/chef-13.0.118/lib"
153
71
  },
154
72
  "ohai": {
155
- "version": "8.11.1",
156
- "ohai_root": "/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/ohai-8.11.1/lib/ohai"
73
+ "version": "13.0.1",
74
+ "ohai_root": "/opt/chef/embedded/lib/ruby/gems/2.4.0/gems/ohai-13.0.1/lib/ohai"
157
75
  }
158
76
  },
77
+ "command": {
78
+ "ps": "ps -ef"
79
+ },
159
80
  "counters": {
160
81
  "network": {
161
82
  "interfaces": {
83
+ "lo": {
84
+ "tx": {
85
+ "queuelen": "1",
86
+ "bytes": 0,
87
+ "packets": 0,
88
+ "errors": 0,
89
+ "drop": 0,
90
+ "carrier": 0,
91
+ "collisions": 0
92
+ },
93
+ "rx": {
94
+ "bytes": 0,
95
+ "packets": 0,
96
+ "errors": 0,
97
+ "drop": 0,
98
+ "overrun": 0
99
+ }
100
+ },
162
101
  "eth0": {
163
102
  "rx": {
164
- "bytes": "0",
165
- "packets": "0",
166
- "errors": "0",
103
+ "bytes": 0,
104
+ "packets": 0,
105
+ "errors": 0,
167
106
  "drop": 0,
168
107
  "overrun": 0,
169
108
  "frame": 0,
@@ -171,12 +110,12 @@
171
110
  "multicast": 0
172
111
  },
173
112
  "tx": {
174
- "bytes": "342",
175
- "packets": "0",
176
- "errors": "0",
113
+ "bytes": 0,
114
+ "packets": 0,
115
+ "errors": 0,
177
116
  "drop": 0,
178
117
  "overrun": 0,
179
- "collisions": "0",
118
+ "collisions": 0,
180
119
  "carrier": 0,
181
120
  "compressed": 0
182
121
  }
@@ -184,7 +123,14 @@
184
123
  }
185
124
  }
186
125
  },
126
+ "cpu": {
127
+ "real": 1,
128
+ "total": 1,
129
+ "cores": 1
130
+ },
187
131
  "current_user": "fauxhai",
132
+ "dmi": {
133
+ },
188
134
  "domain": "local",
189
135
  "etc": {
190
136
  "passwd": {
@@ -205,70 +151,472 @@
205
151
  }
206
152
  }
207
153
  },
208
- "hostname": "Fauxhai",
154
+ "filesystem": {
155
+ "by_device": {
156
+ "/dev/xvda1": {
157
+ "kb_size": "2064208",
158
+ "kb_used": "948464",
159
+ "kb_available": "1094784",
160
+ "percent_used": "47%",
161
+ "total_inodes": "131072",
162
+ "inodes_used": "33316",
163
+ "inodes_available": "97756",
164
+ "inodes_percent_used": "26%",
165
+ "fs_type": "ext4",
166
+ "mount_options": [
167
+ "rw",
168
+ "noatime"
169
+ ],
170
+ "mounts": [
171
+ "/"
172
+ ]
173
+ },
174
+ "tmpfs": {
175
+ "kb_size": "304328",
176
+ "kb_used": "0",
177
+ "kb_available": "304328",
178
+ "percent_used": "0%",
179
+ "total_inodes": "76082",
180
+ "inodes_used": "1",
181
+ "inodes_available": "76081",
182
+ "inodes_percent_used": "1%",
183
+ "fs_type": "tmpfs",
184
+ "mount_options": [
185
+ "rw"
186
+ ],
187
+ "mounts": [
188
+ "/dev/shm"
189
+ ]
190
+ },
191
+ "proc": {
192
+ "fs_type": "proc",
193
+ "mount_options": [
194
+ "rw"
195
+ ],
196
+ "mounts": [
197
+ "/proc"
198
+ ]
199
+ },
200
+ "sysfs": {
201
+ "fs_type": "sysfs",
202
+ "mount_options": [
203
+ "rw"
204
+ ],
205
+ "mounts": [
206
+ "/sys"
207
+ ]
208
+ },
209
+ "devpts": {
210
+ "fs_type": "devpts",
211
+ "mount_options": [
212
+ "rw",
213
+ "gid=5",
214
+ "mode=620"
215
+ ],
216
+ "mounts": [
217
+ "/dev/pts"
218
+ ]
219
+ },
220
+ "none": {
221
+ "fs_type": "binfmt_misc",
222
+ "mount_options": [
223
+ "rw"
224
+ ],
225
+ "mounts": [
226
+ "/proc/sys/fs/binfmt_misc"
227
+ ]
228
+ },
229
+ "rootfs": {
230
+ "fs_type": "rootfs",
231
+ "mount_options": [
232
+ "rw"
233
+ ],
234
+ "mounts": [
235
+ "/"
236
+ ]
237
+ },
238
+ "devtmpfs": {
239
+ "fs_type": "devtmpfs",
240
+ "mount_options": [
241
+ "rw",
242
+ "relatime",
243
+ "size=296148k",
244
+ "nr_inodes=74037",
245
+ "mode=755"
246
+ ],
247
+ "mounts": [
248
+ "/dev"
249
+ ]
250
+ }
251
+ },
252
+ "by_mountpoint": {
253
+ "/": {
254
+ "kb_size": "2064208",
255
+ "kb_used": "948464",
256
+ "kb_available": "1094784",
257
+ "percent_used": "47%",
258
+ "total_inodes": "131072",
259
+ "inodes_used": "33316",
260
+ "inodes_available": "97756",
261
+ "inodes_percent_used": "26%",
262
+ "fs_type": "rootfs",
263
+ "mount_options": [
264
+ "rw"
265
+ ],
266
+ "devices": [
267
+ "/dev/xvda1",
268
+ "rootfs"
269
+ ]
270
+ },
271
+ "/dev/shm": {
272
+ "kb_size": "304328",
273
+ "kb_used": "0",
274
+ "kb_available": "304328",
275
+ "percent_used": "0%",
276
+ "total_inodes": "76082",
277
+ "inodes_used": "1",
278
+ "inodes_available": "76081",
279
+ "inodes_percent_used": "1%",
280
+ "fs_type": "tmpfs",
281
+ "mount_options": [
282
+ "rw"
283
+ ],
284
+ "devices": [
285
+ "tmpfs"
286
+ ]
287
+ },
288
+ "/proc": {
289
+ "fs_type": "proc",
290
+ "mount_options": [
291
+ "rw"
292
+ ],
293
+ "devices": [
294
+ "proc"
295
+ ]
296
+ },
297
+ "/sys": {
298
+ "fs_type": "sysfs",
299
+ "mount_options": [
300
+ "rw"
301
+ ],
302
+ "devices": [
303
+ "sysfs"
304
+ ]
305
+ },
306
+ "/dev/pts": {
307
+ "fs_type": "devpts",
308
+ "mount_options": [
309
+ "rw",
310
+ "gid=5",
311
+ "mode=620"
312
+ ],
313
+ "devices": [
314
+ "devpts"
315
+ ]
316
+ },
317
+ "/proc/sys/fs/binfmt_misc": {
318
+ "fs_type": "binfmt_misc",
319
+ "mount_options": [
320
+ "rw"
321
+ ],
322
+ "devices": [
323
+ "none"
324
+ ]
325
+ },
326
+ "/dev": {
327
+ "fs_type": "devtmpfs",
328
+ "mount_options": [
329
+ "rw",
330
+ "relatime",
331
+ "size=296148k",
332
+ "nr_inodes=74037",
333
+ "mode=755"
334
+ ],
335
+ "devices": [
336
+ "devtmpfs"
337
+ ]
338
+ }
339
+ },
340
+ "by_pair": {
341
+ "/dev/xvda1,/": {
342
+ "device": "/dev/xvda1",
343
+ "kb_size": "2064208",
344
+ "kb_used": "948464",
345
+ "kb_available": "1094784",
346
+ "percent_used": "47%",
347
+ "mount": "/",
348
+ "total_inodes": "131072",
349
+ "inodes_used": "33316",
350
+ "inodes_available": "97756",
351
+ "inodes_percent_used": "26%",
352
+ "fs_type": "ext4",
353
+ "mount_options": [
354
+ "rw",
355
+ "noatime"
356
+ ]
357
+ },
358
+ "tmpfs,/dev/shm": {
359
+ "device": "tmpfs",
360
+ "kb_size": "304328",
361
+ "kb_used": "0",
362
+ "kb_available": "304328",
363
+ "percent_used": "0%",
364
+ "mount": "/dev/shm",
365
+ "total_inodes": "76082",
366
+ "inodes_used": "1",
367
+ "inodes_available": "76081",
368
+ "inodes_percent_used": "1%",
369
+ "fs_type": "tmpfs",
370
+ "mount_options": [
371
+ "rw"
372
+ ]
373
+ },
374
+ "proc,/proc": {
375
+ "device": "proc",
376
+ "mount": "/proc",
377
+ "fs_type": "proc",
378
+ "mount_options": [
379
+ "rw"
380
+ ]
381
+ },
382
+ "sysfs,/sys": {
383
+ "device": "sysfs",
384
+ "mount": "/sys",
385
+ "fs_type": "sysfs",
386
+ "mount_options": [
387
+ "rw"
388
+ ]
389
+ },
390
+ "devpts,/dev/pts": {
391
+ "device": "devpts",
392
+ "mount": "/dev/pts",
393
+ "fs_type": "devpts",
394
+ "mount_options": [
395
+ "rw",
396
+ "gid=5",
397
+ "mode=620"
398
+ ]
399
+ },
400
+ "none,/proc/sys/fs/binfmt_misc": {
401
+ "device": "none",
402
+ "mount": "/proc/sys/fs/binfmt_misc",
403
+ "fs_type": "binfmt_misc",
404
+ "mount_options": [
405
+ "rw"
406
+ ]
407
+ },
408
+ "rootfs,/": {
409
+ "device": "rootfs",
410
+ "mount": "/",
411
+ "fs_type": "rootfs",
412
+ "mount_options": [
413
+ "rw"
414
+ ]
415
+ },
416
+ "devtmpfs,/dev": {
417
+ "device": "devtmpfs",
418
+ "mount": "/dev",
419
+ "fs_type": "devtmpfs",
420
+ "mount_options": [
421
+ "rw",
422
+ "relatime",
423
+ "size=296148k",
424
+ "nr_inodes=74037",
425
+ "mode=755"
426
+ ]
427
+ }
428
+ }
429
+ },
430
+ "fips": {
431
+ "kernel": {
432
+ "enabled": false
433
+ }
434
+ },
209
435
  "fqdn": "fauxhai.local",
436
+ "hostname": "Fauxhai",
437
+ "idle": "30 days 15 hours 07 minutes 30 seconds",
438
+ "idletime_seconds": 2646450,
439
+ "init_package": "init",
210
440
  "ipaddress": "10.0.0.2",
441
+ "kernel": {
442
+ "name": "Linux",
443
+ "release": "3.2.38-5.48.amzn1.x86_64",
444
+ "version": "#1 SMP Wed Feb 13 01:07:25 UTC 2013",
445
+ "machine": "x86_64",
446
+ "processor": "x86_64",
447
+ "os": "GNU/Linux",
448
+ "modules": {
449
+ "ipv6": {
450
+ "size": "317603",
451
+ "refcount": "10"
452
+ },
453
+ "binfmt_misc": {
454
+ "size": "7695",
455
+ "refcount": "1"
456
+ },
457
+ "dm_mod": {
458
+ "size": "75314",
459
+ "refcount": "0"
460
+ },
461
+ "scsi_mod": {
462
+ "size": "199417",
463
+ "refcount": "0"
464
+ },
465
+ "ext4": {
466
+ "size": "456134",
467
+ "refcount": "1"
468
+ },
469
+ "mbcache": {
470
+ "size": "7270",
471
+ "refcount": "1"
472
+ },
473
+ "jbd2": {
474
+ "size": "86039",
475
+ "refcount": "1"
476
+ },
477
+ "crc16": {
478
+ "size": "1557",
479
+ "refcount": "1"
480
+ }
481
+ }
482
+ },
211
483
  "keys": {
212
484
  "ssh": {
213
485
  "host_dsa_public": "ssh-dss AAAAB3NzaC1kc3MAAACBAJFo9BLAw4WKEs5hgipk5m423FzBsDXCZSMcC9ca/om/1VYzMqImixGe3uICDzNFUWxFoLJTQAOccyzo6MXZiQqwWJDLFi5qOSr6w2XcMyE+zd4wOyMoDiVM5fizmG8K3FzrqvGjwBcHcBdOQnavSijoj38DN25J9zhrid5BY4WlAAAAFQDxXrCyG52XCzn3FV4ej38wJBkomQAAAIBovGPJ4mP2P6BK8lHl0PPbktwQbWlpJ13oz6REJFDVcUi7vV26bX/BjQX+ohzZQzljdz1SpUbPc/8nuA4darYkVh91eBi307EN8IdxRHj2eBgp/ZG4yshIebG3WHrwJD/xUjjZ1MRfyDT1ermVi4LvjjPgWDxLZnPpMaR6S1nzgQAAAIEAj0Vd6DCWslvlsZ8+N53HWsqPi3gnx35JoLPz9Z2epkKIKqmEHav+93G3hdfztVa4I4t3phoPniQchYryF5+RNg8hqxKzjNtrIqUYCeuf2NJrksNsH7OZygPHZpqt4kTuwAGZxjxEGfAI0y8DhkU2ntp2LnzRnWH106BQBCmcXwo= fauxhai.local",
214
486
  "host_rsa_public": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCtLCeqtqr/HbnORckw1ukdLhpfGoOPFi5/esKEokzTqq1gsgQ2V8emmyjfq1i6XXfRtSBxkdlHv/GWdP5wBTuE2G85MzBkVSQPvmwQN8lX/JMPEEtKXkeOo0o92/PiSmvY4eRsdF0mw40Uvg7jtE3f3fxj497kzh5fKtkrHnF4x9gXCbVdr3FqXJfggR5IJwAxToerbK7x/uRS+7YuZI9Pip3tt14nv9ezwXcuGb/tvjWOZINiFl8izVIFKi7sxfTX09p4NgamxRS7TD2Yd0jT8nEoF9UZTsgXcJ1kDSx7N7NxFfNfP6rCdOGRRz4gUhXtsUjG/XkxPeCwZ7A9VnOD fauxhai.local"
215
487
  }
216
488
  },
489
+ "languages": {
490
+ "ruby": {
491
+ "bin_dir": "/usr/local/bin",
492
+ "gem_bin": "/usr/local/bin/gem",
493
+ "gems_dir": "/usr/local/gems",
494
+ "ruby_bin": "/usr/local/bin/ruby"
495
+ },
496
+ "powershell": null
497
+ },
498
+ "lsb": {
499
+ },
217
500
  "macaddress": "11:11:11:11:11:11",
501
+ "machinename": "Fauxhai",
502
+ "memory": {
503
+ "total": "1048576kB"
504
+ },
218
505
  "network": {
219
- "default_gateway": "10.0.0.1",
220
- "default_interface": "eth0",
221
- "settings": {
222
- },
223
506
  "interfaces": {
224
- "eth0": {
507
+ "lo": {
508
+ "mtu": "65536",
509
+ "flags": [
510
+ "LOOPBACK",
511
+ "UP",
512
+ "LOWER_UP"
513
+ ],
514
+ "encapsulation": "Loopback",
225
515
  "addresses": {
226
- "10.0.0.2": {
227
- "broadcast": "10.0.0.255",
516
+ "127.0.0.1": {
228
517
  "family": "inet",
229
- "netmask": "255.255.255.0",
230
- "prefixlen": "24",
231
- "scope": "Global"
518
+ "prefixlen": "8",
519
+ "netmask": "255.0.0.0",
520
+ "scope": "Node",
521
+ "ip_scope": "LOOPBACK"
522
+ },
523
+ "::1": {
524
+ "family": "inet6",
525
+ "prefixlen": "128",
526
+ "scope": "Node",
527
+ "tags": [
528
+
529
+ ],
530
+ "ip_scope": "LINK LOCAL LOOPBACK"
232
531
  }
233
532
  },
234
- "arp": {
235
- "10.0.0.1": "fe:ff:ff:ff:ff:ff"
236
- },
237
- "encapsulation": "Ethernet",
533
+ "state": "unknown"
534
+ },
535
+ "eth0": {
536
+ "type": "eth",
537
+ "number": "0",
538
+ "mtu": "1500",
238
539
  "flags": [
239
540
  "BROADCAST",
240
541
  "MULTICAST",
241
542
  "UP",
242
543
  "LOWER_UP"
243
544
  ],
244
- "mtu": "1500",
245
- "number": "0",
545
+ "encapsulation": "Ethernet",
546
+ "addresses": {
547
+ "11:11:11:11:11:11": {
548
+ "family": "lladdr"
549
+ },
550
+ "10.0.0.2": {
551
+ "family": "inet",
552
+ "prefixlen": "24",
553
+ "netmask": "255.255.255.0",
554
+ "broadcast": "10.0.0.255",
555
+ "scope": "Global",
556
+ "ip_scope": "RFC1918 PRIVATE"
557
+ },
558
+ "fe80::11:1111:1111:1111": {
559
+ "family": "inet6",
560
+ "prefixlen": "64",
561
+ "scope": "Link",
562
+ "tags": [
563
+
564
+ ],
565
+ "ip_scope": "LINK LOCAL UNICAST"
566
+ }
567
+ },
568
+ "state": "up",
569
+ "arp": {
570
+ "10.0.0.1": "fe:ff:ff:ff:ff:ff"
571
+ },
246
572
  "routes": [
573
+ {
574
+ "destination": "default",
575
+ "family": "inet",
576
+ "via": "10.0.0.1"
577
+ },
247
578
  {
248
579
  "destination": "10.0.0.0/24",
249
580
  "family": "inet",
250
581
  "scope": "link",
251
582
  "proto": "kernel",
252
583
  "src": "10.0.0.2"
584
+ },
585
+ {
586
+ "destination": "fe80::/64",
587
+ "family": "inet6",
588
+ "metric": "256",
589
+ "proto": "kernel"
253
590
  }
254
591
  ],
255
- "state": "up",
256
- "type": "eth"
592
+ "ring_params": {
593
+ }
257
594
  }
258
- }
595
+ },
596
+ "default_interface": "eth0",
597
+ "default_gateway": "10.0.0.1"
259
598
  },
260
- "uptime": "30 days 15 hours 07 minutes 30 seconds",
261
- "uptime_seconds": 2646450,
262
- "cpu": {
263
- "real": 1,
264
- "total": 1,
265
- "cores": 1
599
+ "ohai_time": 1492225971.0716958,
600
+ "os": "linux",
601
+ "os_version": "3.2.38-5.48.amzn1.x86_64",
602
+ "packages": {
266
603
  },
267
- "memory": {
268
- "total": "1048576kB"
604
+ "platform": "amazon",
605
+ "platform_family": "amazon",
606
+ "platform_version": "2012.09",
607
+ "root_group": "root",
608
+ "shells": [
609
+ "/bin/sh",
610
+ "/bin/bash",
611
+ "/sbin/nologin"
612
+ ],
613
+ "time": {
614
+ "timezone": "GMT"
269
615
  },
616
+ "uptime": "30 days 15 hours 07 minutes 30 seconds",
617
+ "uptime_seconds": 2646450,
270
618
  "virtualization": {
271
619
  "systems": {
272
620
  }
273
621
  }
274
- }
622
+ }