Skip to content

Commit

Permalink
Added validation for openstack winrm password
Browse files Browse the repository at this point in the history
  • Loading branch information
siddheshwar-more committed Jul 26, 2013
1 parent d5f9b9c commit 288636b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/chef/knife/openstack_server_create.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,9 @@ def validate_params!
errors << "You must provide SSH Key."
end
elsif locate_config_value(:bootstrap_protocol) == 'winrm'
super(:winrm_user, :winrm_password)
if locate_config_value(:winrm_password).nil?
errors << "You must provide Winrm Password."
end
else
errors << "You must provide a valid bootstrap protocol. options [ssh/winrm]. For linux type images, options [ssh]"
end
Expand Down

0 comments on commit 288636b

Please sign in to comment.