Looks good, just not sure why you re implemented apt/yum as you should
be able to chain into the existing modules.
There's no daisy chaining anymore, actually. And it's more efficient that way.
There are built-in functions so modules like copy can access the
functions of modules like file.
To me, I think, this could /probably/ be simplified to a playbook of
maybe 30-40 lines, unless you were really concerned about it only
being one hop.
Code quality is great though
Damn, missed when this happened, probably when copy/file functions got
moved into common.
On Fri, Jan 25, 2013 at 4:13 PM, Michael DeHaan
Thanks for the feedback. I’m aware of the icky code duplication issues, and this was because it didn’t look like I could call into other modules or non-standard libraries. This module started life as a playbook until it just became way too complicated for that format.
Can you add information on how to run this playbook/module (or whatever it is) ? I’m inclined to think I can run it with just Python by calling ‘python java.py’, but I doubt it is that straightforward?
It’s an Ansible module.
For what it’s worth, I recently created a role for installing Sun Java on Ubuntu. It’s not as generic as Lisa’s module, but could maybe serve as a foundation for something better.
See: https://letscrate.com/f/jcassee/ansible/java.zip
Some notes:
- Installs StartSSL certificates into the cacerts keystore.
- Registers a variable because Java-based services in other roles may need to be restarted.
Regards,
Joost
my oracle java role in galxy https://galaxy.ansible.com/list#/roles/628, there are others