Sha256: 793a2fc2d597f0a233e9df1467e26248d5caa5f7f1ed4636a453ca21fa4fc276

Contents?: true

Size: 292 Bytes

Versions: 15

Compression:

Stored size: 292 Bytes

Contents

require "chef/client"
require 'rbconfig'

if File.exists?("/etc/chef/client.rb")
  Chef::Config.from_file("/etc/chef/client.rb")
end
client = Chef::Client.new
if Ohai::Config[:file]
  client.ohai.from_file(Ohai::Config[:file])
else
  client.ohai.all_plugins
end
puts ""
puts client.node_name

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
motherbrain-1.5.0 scripts/node_name.rb
motherbrain-1.4.0 scripts/node_name.rb
motherbrain-1.3.0 scripts/node_name.rb
motherbrain-1.2.1 scripts/node_name.rb
motherbrain-1.2.0 scripts/node_name.rb
motherbrain-1.1.3 scripts/node_name.rb
motherbrain-1.1.2 scripts/node_name.rb
motherbrain-1.1.1 scripts/node_name.rb
motherbrain-1.1.0 scripts/node_name.rb
motherbrain-1.0.0 scripts/node_name.rb
motherbrain-0.14.5 scripts/node_name.rb
motherbrain-0.14.4 scripts/node_name.rb
motherbrain-0.14.3 scripts/node_name.rb
motherbrain-0.14.2 scripts/node_name.rb
motherbrain-0.13.1 scripts/node_name.rb