diff options
-rw-r--r-- | lib/chef/knife/core/bootstrap_context.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/chef/knife/core/bootstrap_context.rb b/lib/chef/knife/core/bootstrap_context.rb index 6f1c234796..7ad70bc627 100644 --- a/lib/chef/knife/core/bootstrap_context.rb +++ b/lib/chef/knife/core/bootstrap_context.rb @@ -127,7 +127,13 @@ validation_client_name "#{@chef_config[:validation_client_name]}" end if Chef::Config[:fips] - client_rb << %Q{fips true\n} + client_rb << <<-CONFIG +fips true +chef_version = ::Chef::VERSION.split(".") +unless chef_version[0].to_i > 12 || (chef_version[0].to_i == 12 && chef_version[1].to_i >= 8) + raise "FIPS Mode requested but not supported by this client" +end +CONFIG end client_rb |