summaryrefslogtreecommitdiff
path: root/lib/chef/knife.rb
Commit message (Collapse)AuthorAgeFilesLines
* Add Knife::Core::UI#edit_hashSteven Danna2015-02-091-0/+1
| | | | | | edit_hash is similar to edit_data except that it returns an uninflated hash. edit_data returns either a string/IO, a hash, or a full ruby object, making it difficult to work with.
* Merge pull request #2760 from troyready/msng_plug_msgLamont Granquist2015-01-281-1/+2
|\ | | | | Update knife missing gem message for ChefDK
| * update knife missing gem message for chefdkTroy Ready2015-01-151-1/+2
| |
* | Fix typo cab to candrag00n2015-01-111-1/+1
|/
* Add specific error messaging for SSL errors to knifedanielsdeleo2014-12-151-0/+7
| | | | | | | | | | | | | | Knife now gives an error message like this when an SSL error occurs: ``` ERROR: Could not establish a secure connection to the server. Use `knife ssl check` to troubleshoot your SSL configuration. If your Chef Server uses a self-signed certificate, you can use `knife ssl fetch` to make knife trust the server's certificates. Original Exception: OpenSSL::SSL::SSLError: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed ```
* Fix knife plugin path searchingLamont Granquist2014-12-031-3/+11
| | | | | | | | | | | | | | | | | | Unreleased Chef 12.0.0 bug caught in testing where only the searching upwards from PWD to find .chef in order to get the plugin path for knife was busted. The chef_config_dir was being used before load_config was being called, so it was nil, which broke finding knife plugins. This was fixed by adding some lazy initialization of the config_loader object itself and the chef_config_dir. The reset_config_loader! is added entirely to reset the global state for unit testing. This whole class is a bit horrible and needs to have all its global state removed from it, class methods removed, class ivars and the class-variable-in-a-class-method-for-inheritance-lolwut needs to be removed. Unfortunately, that requires some delicate surgery because Chef::Knife gets used as a public API, and is beyond the scope of gettting Chef 12 shipped.
* typo fixes - https://github.com/vlajos/misspell_fixerVeres Lajos2014-11-081-1/+1
|
* print the path to the configuration file usedAlex Pop2014-10-041-1/+2
|
* Add debug/info logging for knife config file findingdanielsdeleo2014-09-031-1/+13
| | | | | | | To resolve a chicken/egg issue with the logger being configured *after* the config is located and read, knife will now check for a KNIFE_DEBUG variable and initialize the logger to debug early in the startup process when that variable is set.
* Extract Knife config file find/load to a reusable componentdanielsdeleo2014-09-031-121/+24
|
* Refactor caller decorations into with_server_connectivityJohn Keiser2014-07-071-4/+1
|
* Move local-mode server connectivity code to Chef::LocalModeJohn Keiser2014-07-071-3/+3
|
* making the chef-zero host configurable for knife and chef-clientLuke Amdor2014-06-051-0/+1
|
* Add SSL check and certificate fetching commands to knifedanielsdeleo2014-03-191-0/+1
| | | | Fixes CHEF-4711
* remove debugging putsLamont Granquist2013-12-131-1/+0
|
* Check for ENV['CD'] instead of ENV['PWD'] on windows.sersut2013-11-051-1/+8
| | | | Also the associated test is removed as I am not sure how it should be fixed.
* Fixup specs to handle config jail featuredanielsdeleo2013-10-161-1/+5
|
* Flip config_missing? to return true when missingJohn Keiser2013-10-161-1/+1
|
* Load client/solo config via ConfigFetcherdanielsdeleo2013-10-161-17/+19
| | | | | * Uses Chef::HTTP::Simple rather than Chef::REST to fetch files * Re-use error handling logic in ConfigFetcher
* Add --config-file-jail to avoid loading user knife.rb in testsJohn Keiser2013-10-151-4/+8
|
* Pick up knife config instead of /etc/chef/client.rb if local mode is specifiedJohn Keiser2013-10-091-6/+7
|
* Make --local-mode option so that local user can run local recipesJohn Keiser2013-10-091-1/+4
|
* Add -z and --chef-zero-port options to knife and chef-clientJohn Keiser2013-10-021-0/+3
|
* Add tests for start_chef_zero parameter in knifeJohn Keiser2013-10-021-5/+8
|
* Support start_chef_zero parameter in knife and chef-clientJohn Keiser2013-10-021-0/+2
|
* sorting subcommands, this will display all subcommands in the order a..zSander Botman2013-05-301-1/+1
|
* [CHEF-3932] Support multiple calls of `Knife.deps`Teemu Matilainen2013-04-111-2/+8
| | | | | | If a Knife subcommand class were inheriting or including other classes with lazy loading dependencies, a later call to `Knife.deps` overwrote the earlier block. Fix it by collecting the blocks to an array.
* [CHEF-2682] raise exception on non-GET/HEAD redirectsLoic ANTOINE-GOMBEAUD2013-03-061-0/+3
|
* [CHEF-3497] apply config in the desired orderdanielsdeleo2013-01-141-29/+52
| | | | | | | | | Takes advantage of new mixlib-cli option to keep default values from the mixlib-cli DSL separate from user-supplied values. Config settings are merged: 1. Defaults from mixlib-cli DSL 2. Settings from Chef::Config[:knife] 3. Values from CLI options
* [CHEF-3497] don't configure in Knife#initializedanielsdeleo2013-01-141-2/+2
| | | | | | Config changes a ton of global state and is based on the state of the machine it runs on (most importantly, the user's config file). Running configure_chef in the initializer makes unit tests extremely fragile
* Update stubbing order within config specChris Roberts2013-01-141-1/+1
|
* Isolate knife config file location methodology. Use new locate method when ↵Chris Roberts2013-01-111-27/+38
| | | | configuring
* Allow knife.rb configuration file to provide any options for knife pluginsChris Roberts2013-01-111-1/+10
|
* [CHEF-3663] Search for .chef in ENV[PWD] if setdanielsdeleo2012-12-051-2/+11
| | | | | | Prefer ENV["PWD"] for current working dir, but fall back to Dir.pwd if not set. Fixes config path searching when part of the path hierarchy is a symlinked directory.
* [OC-3564] move core Chef to the repo root \o/ \m/Seth Chisamore2012-10-301-0/+537
The opscode/chef repository now only contains the core Chef library code used by chef-client, knife and chef-solo!