Appdynamics / Appdynamics/appdynamics-cookbooks
guard_interpreter does not support blocks
- Dominant language
- Ruby
- Stars
- 28
- Forks
- 35
- PR merge metrics
- No merged PRs in 30d
Description
Getting this error when trying to install app dynamics on new web servers.
```
version
appdynamics: 0.2.4
chef-client: 12.17.44
```
```
(skipped due to action :nothing)
* powershell_script[Restart IIS] action nothing[2017-01-17T17:34:34-05:00] INFO: Processing powershell_script[Restart
IIS] action nothing (appdynamics::dotnet_agent line 89)
(skipped due to action :nothing)
[2017-01-17T17:34:34-05:00] INFO: windows_package[AppDynamics .NET Agent] sending restart action to windows_service[NetS
age] (delayed)
* windows_service[NetSage] action restart[2017-01-17T17:34:34-05:00] INFO: Processing windows_service[NetSage] action
restart (appdynamics::dotnet_agent line 77)
================================================================================
Error executing action `restart` on resource 'windows_service[NetSage]'
================================================================================
ArgumentError
-------------
NetSage was given a guard_interpreter of powershell_script, but not given a command as a string. guard_interpreter d
oes not support blocks (because they just contain ruby).
Resource Declaration:
---------------------
# In c:/chef/cache/cookbooks/appdynamics/recipes/dotnet_agent.rb
77: service apps['name'] do # ~FC022
78: action :nothing
79: subscribes :restart, 'service[AppDynamics.Agent.Coordinator_service]', :delayed
80: subscribes :restart, 'windows_package[AppDynamics .NET Agent]', :delayed
81: only_if { apps['restart'] == true }
82: end
83: end
Compiled Resource:
------------------
# Declared in c:/chef/cache/cookbooks/appdynamics/recipes/dotnet_agent.rb:77:in `block in from_file'
windows_service("NetSage") do
action [:nothing]
supports {:restart=>nil, :reload=>nil, :status=>nil}
retries 0
retry_delay 2
guard_interpreter :powershell_script
default_guard_interpreter :default
service_name "NetSage"
pattern "NetSage"
startup_type :automatic
declared_type :service
cookbook_name "appdynamics"
recipe_name "dotnet_agent"
only_if { #code block }
end
Platform:
---------
x64-mingw32
[2017-01-17T17:34:34-05:00] INFO: windows_package[AppDynamics .NET Agent] sending run action to powershell_script[Restart IIS] (delayed)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in appdynamics::dotnet_agent at recipe line 77 and inspect the windows_service declaration, especially its guard_interpreter and only_if entries. Reproduce the reported installation with the listed Chef and cookbook versions; done means the NetSage restart no longer raises the guard_interpreter ArgumentError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- devops
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100