You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to write some test_kitchen/serverspec tests for my wrapper cookbook that I use internally. I am running into issues with the rundeck::default.rb recipe around likes 91.
Here we check for chef_solo as I don't believe there is good way to check chef_zero. This results in compilation failure when running with chef_zero as it attempts to search the in memory chef server for data bag items that do not exist.
I have switched to using chef_solo for now, but would prefer using chef_zero in the future. Not entirely sure the best way to handle it. I have thought about adding an attribute that we can just set true/false to tell it weather to search or not but I am not crazy about that, just not sure of another way at the moment.
recipients = if Chef::Config[:solo] || node['rundeck']['test_run']
The text was updated successfully, but these errors were encountered:
This can be solved by adding an array node attribute to statically define recipients, that will override the data bag based search if the attribute is not set to nil. Something like node['rundeck']['mail']['recipients'] = ['root']. Does this sound like a good approach to you?
I am trying to write some test_kitchen/serverspec tests for my wrapper cookbook that I use internally. I am running into issues with the rundeck::default.rb recipe around likes 91.
Here we check for chef_solo as I don't believe there is good way to check chef_zero. This results in compilation failure when running with chef_zero as it attempts to search the in memory chef server for data bag items that do not exist.
I have switched to using chef_solo for now, but would prefer using chef_zero in the future. Not entirely sure the best way to handle it. I have thought about adding an attribute that we can just set true/false to tell it weather to search or not but I am not crazy about that, just not sure of another way at the moment.
The text was updated successfully, but these errors were encountered: