We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
As of 18.4.2, the windows_service resource does not process the description property/argument correctly. Example code:
windows_service
description
windows_service service_name do binary_path_name startup_command name new_resource.agent_name description "#{new_resource.agent_name} agent" delayed_start false timeout 30 action %i[create enable start] end
The error is:
NoMethodError ------------- undefined method `description' for #<struct Struct::ServiceConfigInfo service_type="own process", start_type="auto start", error_control="normal", binary_path_name="C:/vault/vault.exe agent -config=C:/vault/config/agent.hcl ", load_order_group="", tag_id=0, dependencies=[], service_start_name="LocalSystem", display_name="vault"> current_resource.description(config_info.description) if new_resource.description ^^^^^^^^^^^^
Removing the description property from the resource works around the problem.
18.4.2 (was working in 18.3.0)
System Info: ------------ chef_version=18.4.2 platform=windows platform_version=10.0.17763 ruby=ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [x64-mingw-ucrt]
C:/cinc-project/cinc/embedded/lib/ruby/gems/3.1.0/gems/chef-18.4.2-x64-mingw-ucrt/lib/chef/provider/service/windows.rb:77:in `load_current_resource' C:/cinc-project/cinc/embedded/lib/ruby/gems/3.1.0/gems/chef-18.4.2-x64-mingw-ucrt/lib/chef/provider.rb:228:in `run_action' C:/cinc-project/cinc/embedded/lib/ruby/gems/3.1.0/gems/chef-18.4.2-x64-mingw-ucrt/lib/chef/resource.rb:601:in `block in run_action'
The text was updated successfully, but these errors were encountered:
This is a result of #14064. ServiceConfigInfo does not include a description field, do we even test things anymore?
ServiceConfigInfo
https://github.com/chef/win32-service/blob/67a0f7ac46a5e0332d95867f1ee2e7cd733b9117/lib/win32/service.rb#L206-L217
Sorry, something went wrong.
This is also happening on Chef 17.10.122
Makes sense. They backported the change I referenced into 17 here. #14151
They need to either revert or add the description field to the win32-service library.
tpowell-progress
No branches or pull requests
Description
As of 18.4.2, the
windows_service
resource does not process thedescription
property/argument correctly. Example code:The error is:
Removing the
description
property from the resource works around the problem.Chef Version
18.4.2 (was working in 18.3.0)
Platform Version
Stacktrace
The text was updated successfully, but these errors were encountered: