Class: Chef::Knife::Bootstrap
- Inherits:
-
Object
- Object
- Chef::Knife::Bootstrap
- Defined in:
- lib/chef/knife/bootstrap_solo.rb
Class Method Summary collapse
Instance Method Summary collapse
- #run ⇒ Object
-
#run_with_chef_client ⇒ Object
Rename and override run method.
-
#run_with_knife_solo ⇒ Object
Bootstraps Chef on the node using knife-solo.
Class Method Details
.load_deps ⇒ Object
7 8 9 10 11 12 |
# File 'lib/chef/knife/bootstrap_solo.rb', line 7 def self.load_deps super require 'chef/knife/solo_bootstrap' require 'knife-solo/tools' SoloBootstrap.load_deps end |
Instance Method Details
#run ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/chef/knife/bootstrap_solo.rb', line 21 def run if KnifeSolo::Tools.config_value(config, :solo) run_with_knife_solo else run_with_chef_client end end |
#run_with_chef_client ⇒ Object
Rename and override run method
19 |
# File 'lib/chef/knife/bootstrap_solo.rb', line 19 alias_method :run_with_chef_client, :run |
#run_with_knife_solo ⇒ Object
Bootstraps Chef on the node using knife-solo
30 31 32 33 34 35 36 37 |
# File 'lib/chef/knife/bootstrap_solo.rb', line 30 def run_with_knife_solo validate_name_args! bootstrap = SoloBootstrap.new bootstrap.name_args = @name_args bootstrap.config.merge! config bootstrap.run end |