diff options
author | Tim Smith <tsmith@chef.io> | 2019-05-06 22:44:59 -0700 |
---|---|---|
committer | Tim Smith <tsmith@chef.io> | 2019-05-07 09:25:42 -0700 |
commit | 5db7159bf4c1b0e04391cc9f4f6c96de050bdd1e (patch) | |
tree | e4a779833081f82274178e0374454c2a3047019f | |
parent | 368bff37a198368883ba44613bff545597b937e7 (diff) | |
download | chef-5db7159bf4c1b0e04391cc9f4f6c96de050bdd1e.tar.gz |
Remove the Chef 11 admin flag from knife client create
We've already removed the other support for setting up users on a Chef 11 server. This just further drops support for old Server installs.
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r-- | lib/chef/knife/client_create.rb | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/lib/chef/knife/client_create.rb b/lib/chef/knife/client_create.rb index 869e174453..d87951555f 100644 --- a/lib/chef/knife/client_create.rb +++ b/lib/chef/knife/client_create.rb @@ -30,13 +30,7 @@ class Chef option :file, short: "-f FILE", long: "--file FILE", - description: "Write the private key to a file if the server generated one." - - option :admin, - short: "-a", - long: "--admin", - description: "Open Source Chef Server 11 only. Create the client as an admin.", - boolean: true + description: "Write the private key to a file if the #{Chef::Dist::SERVER_PRODUCT} generated one." option :validator, long: "--validator", @@ -51,7 +45,7 @@ class Chef option :prevent_keygen, short: "-k", long: "--prevent-keygen", - description: "API V1 (#{Chef::Dist::SERVER_PRODUCT} 12.1+) only. Prevent server from generating a default key pair for you. Cannot be passed with --public-key.", + description: "Prevent #{Chef::Dist::SERVER_PRODUCT} from generating a default key pair for you. Cannot be passed with --public-key.", boolean: true banner "knife client create CLIENTNAME (options)" @@ -79,10 +73,6 @@ class Chef client.create_key(true) end - if config[:admin] - client.admin(true) - end - if config[:validator] client.validator(true) end |