diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-05 15:00:00 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2016-02-05 15:00:00 -0800 |
commit | 686113531d23f30e9973d659c456ae33eb9cff1f (patch) | |
tree | f225de7251a8b49b8d183dd168bab0a0addbe23f /lib/chef/provider/service/windows.rb | |
parent | d1cf34b059a16a81e0fc48de52ba29863bb41fe6 (diff) | |
download | chef-686113531d23f30e9973d659c456ae33eb9cff1f.tar.gz |
autofixing whitespace cops
4174 Style/SpaceInsideHashLiteralBraces
1860 Style/SpaceAroundOperators
1336 Style/SpaceInsideBlockBraces
1292 Style/AlignHash
997 Style/SpaceAfterComma
860 Style/SpaceAroundEqualsInParameterDefault
310 Style/EmptyLines
294 Style/IndentationConsistency
267 Style/TrailingWhitespace
238 Style/ExtraSpacing
212 Style/SpaceBeforeBlockBraces
166 Style/MultilineOperationIndentation
144 Style/TrailingBlankLines
120 Style/EmptyLineBetweenDefs
101 Style/IndentationWidth
82 Style/SpaceAroundBlockParameters
40 Style/EmptyLinesAroundMethodBody
29 Style/EmptyLinesAroundAccessModifier
1 Style/RescueEnsureAlignment
Diffstat (limited to 'lib/chef/provider/service/windows.rb')
-rw-r--r-- | lib/chef/provider/service/windows.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/chef/provider/service/windows.rb b/lib/chef/provider/service/windows.rb index 8c7c76df3f..2705aa5c02 100644 --- a/lib/chef/provider/service/windows.rb +++ b/lib/chef/provider/service/windows.rb @@ -45,7 +45,7 @@ class Chef::Provider::Service::Windows < Chef::Provider::Service START_PENDING = "start pending" STOP_PENDING = "stop pending" - TIMEOUT = 60 + TIMEOUT = 60 SERVICE_RIGHT = "SeServiceLogonRight" @@ -75,7 +75,7 @@ class Chef::Provider::Service::Windows < Chef::Provider::Service service_name: @new_resource.service_name, service_start_name: @new_resource.run_as_user, password: @new_resource.run_as_password, - }.reject { |k,v| v.nil? || v.length == 0 } + }.reject { |k, v| v.nil? || v.length == 0 } Win32::Service.configure(new_config) Chef::Log.info "#{@new_resource} configured with #{new_config.inspect}" @@ -238,6 +238,7 @@ class Chef::Provider::Service::Windows < Chef::Provider::Service end private + def grant_service_logon(username) begin Chef::ReservedNames::Win32::Security.add_account_right(canonicalize_username(username), SERVICE_RIGHT) |