I’m trying to deploy multiple java applications with the java wrapper
cookbook. What the java wrapper does is:
- download the java wrapper, unpack it
- copy files to a specified directory
- create a service and start it.
what it needs is:
- the name of the the service and the place where to find the jars.
The java-wrapper works for a single application (I’ve shared the cookbook
on the site).
What I was planning to do was, for each application do something like:
- recipe A:
override[java-wrapper][name] = a
- recipe B:
override[java-wrapper][name] = b
hoping that the java_wrapper recipe would be called once with a attribute
and once again with b attribute. But what is happening is that the
"java_wrapper" recipe is run only once. After re-reading chef
documentation, I’m not even sure the attribute java-wrapper/name can have
value a and then b during a chef-client run.
What would be a good way to solve the original problem ?