diff options
author | Thom May <thom@may.lt> | 2017-12-18 18:31:58 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-12-18 18:31:58 +0000 |
commit | 925051d67b36a2b6c6a13c99cccf4109e99987f5 (patch) | |
tree | 087260689310c208d67eed36cab4e7cd62e9f5fd /lib/chef/knife.rb | |
parent | eccc48d63e3bc99d161ad6ca48f7770fcd2b9b59 (diff) | |
parent | 92671398a99bb4393650f4343c3b2a20814eb3eb (diff) | |
download | chef-925051d67b36a2b6c6a13c99cccf4109e99987f5.tar.gz |
Merge pull request #6660 from chef/tm/credentials
implement credential management
Diffstat (limited to 'lib/chef/knife.rb')
-rw-r--r-- | lib/chef/knife.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/chef/knife.rb b/lib/chef/knife.rb index 65d687af70..663649f32f 100644 --- a/lib/chef/knife.rb +++ b/lib/chef/knife.rb @@ -177,8 +177,9 @@ class Chef @config_loader ||= WorkstationConfigLoader.new(nil, Chef::Log) end - def self.load_config(explicit_config_file) + def self.load_config(explicit_config_file, profile) config_loader.explicit_config_file = explicit_config_file + config_loader.profile = profile config_loader.load ui.warn("No knife configuration file found") if config_loader.no_config_found? @@ -404,7 +405,7 @@ class Chef def configure_chef # knife needs to send logger output to STDERR by default Chef::Config[:log_location] = STDERR - config_loader = self.class.load_config(config[:config_file]) + config_loader = self.class.load_config(config[:config_file], config[:profile]) config[:config_file] = config_loader.config_location # For CLI options like `--config-option key=value`. These have to get |