I am writing a cookbook that uses the Custom Resources present in Chef 12.5. I have a custom resource that uses a template resource and as such has a notifies that reloads the associated service.
However the associated service is managed in the main recipe. Currently this fails as it complains that there is no service.
In previous versions when using LWRPs this was caused by using use_inline_resources, and I believe you could side-step this particular issue by NOT including this function in your LWRP.
Now I am NOT including this line in my custom resource but the behaviour is present. Is there any way to turn off this behaviour?
Alternatively is there some other way of "including" the service in multiple resources so I don't have to have the exact same code in many many places?