diff options
author | Marc A. Paradise <marc.paradise@gmail.com> | 2021-09-08 17:20:15 -0400 |
---|---|---|
committer | Marc A. Paradise <marc.paradise@gmail.com> | 2021-09-08 17:22:07 -0400 |
commit | 58d8401a96ffdbc06f6e0fe0711122aa699f1007 (patch) | |
tree | 83492b5c5bed6a6f47baaef2f82bb1ad36a9d3f1 /lib/chef/secret_fetcher.rb | |
parent | c81c085f6f6d3fc058d71c8295d0b5620709198b (diff) | |
download | chef-58d8401a96ffdbc06f6e0fe0711122aa699f1007.tar.gz |
Add akeyless vault fetcher
Signed-off-by: Marc A. Paradise <marc.paradise@gmail.com>
Diffstat (limited to 'lib/chef/secret_fetcher.rb')
-rw-r--r-- | lib/chef/secret_fetcher.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/chef/secret_fetcher.rb b/lib/chef/secret_fetcher.rb index e8e4602bb2..af3e1d5cbb 100644 --- a/lib/chef/secret_fetcher.rb +++ b/lib/chef/secret_fetcher.rb @@ -21,7 +21,7 @@ require_relative "exceptions" class Chef class SecretFetcher - SECRET_FETCHERS = %i{example aws_secrets_manager azure_key_vault hashi_vault}.freeze + SECRET_FETCHERS = %i{example aws_secrets_manager azure_key_vault hashi_vault akeyless_vault}.freeze # Returns a configured and validated instance # of a [Chef::SecretFetcher::Base] for the given @@ -45,10 +45,13 @@ class Chef when :hashi_vault require_relative "secret_fetcher/hashi_vault" Chef::SecretFetcher::HashiVault.new(config, run_context) + when :akeyless_vault + require_relative "secret_fetcher/akeyless_vault" + Chef::SecretFetcher::AKeylessVault.new(config, run_context) when nil, "" raise Chef::Exceptions::Secret::MissingFetcher.new(SECRET_FETCHERS) else - raise Chef::Exceptions::Secret::InvalidFetcherService.new("Unsupported secret service: #{service}", SECRET_FETCHERS) + raise Chef::Exceptions::Secret::InvalidFetcherService.new("Unsupported secret service: '#{service}'", SECRET_FETCHERS) end fetcher.validate! fetcher |