Class: Ironfan::Provider::ChefServer
- Inherits:
-
Ironfan::Provider
- Object
- Builder
- Ironfan::Provider
- Ironfan::Provider::ChefServer
- Defined in:
- lib/ironfan/headers.rb,
lib/ironfan/provider/chef.rb,
lib/ironfan/provider/chef/node.rb,
lib/ironfan/provider/chef/role.rb,
lib/ironfan/provider/chef/client.rb
Defined Under Namespace
Class Method Summary collapse
-
.post_rest(type, content, options = {}) ⇒ Object
Utility functions.
- .resources ⇒ Object
- .search(*params, &block) ⇒ Object
Methods inherited from Ironfan::Provider
aggregate!, forget!, load, prepare!, receive, #resources, validate
Methods inherited from Builder
Class Method Details
.post_rest(type, content, options = {}) ⇒ Object
Utility functions
14 15 16 17 18 19 20 21 |
# File 'lib/ironfan/provider/chef.rb', line 14 def self.post_rest(type, content, ={}) params = [ Chef::Config[:chef_server_url] ] if [:client] params << [:client].name params << [:client].key_filename end Chef::REST.new(*params).post_rest(type,content) end |
.resources ⇒ Object
7 8 9 |
# File 'lib/ironfan/provider/chef.rb', line 7 def self.resources [ Client, Node, Role ] end |
.search(*params, &block) ⇒ Object
23 24 25 |
# File 'lib/ironfan/provider/chef.rb', line 23 def self.search(*params,&block) Chef::Search::Query.new.search(*params,&block) end |