Closed luan-cestari closed 9 years ago
Included stdin so I could use anchor (which is default included on the newest puppet version but I worried about backward comparability)
Posted about the problem on https://groups.google.com/forum/#!forum/puppet-users (the post needs to be approved) and also on IRC (#puppet channel in FreeNode)
The link to the post https://groups.google.com/forum/#!topic/puppet-users/CDz_nsjFOKw
Note: the impact of the line commented is not very high as it is necessary in case the alternatives was not set, which is not the case in the RPM packages provided. If there is no suggestion about how to solve this scenario we can leave another issue open referring the puppet's google group post or even removing the 'alternative install' from that class.
I will remove the stdlib and make some changes, such as:
Note: with the complete version of the package and the architecture of the system I can get the exactly package (like when query for it using something like "yum --showduplicates list java-1.8.0-openjdk-1.8.0.25-4.b18.fc21" would a package per architecture and as I know the architecture I can decide the exactly package )
I feel like a lot more is being changed in this PR than the subject indicates. Should this maybe be multiple PRs?
Note: we can add a custom fact trying some distributions of java (such as repoquery java-1.8* | fgrep devel | fgrep openjdk | fgrep -v debug | sed 's/i686$//' | sed 's/x86_64$//' | sed 's/noarch$//' | sed 's/.$//' | sed 's/-1:/-/' | sed 's/devel-//' | sort | uniq | tail -n 1
)
Build failing, looks like lint issues. See for example https://travis-ci.org/lightblue-platform/lightblue-puppet/jobs/57975437#L400-L403
Fixed lint problem. Changed the ensure to check the version of the package and I also removed two alternatives configurations that are only present in java 1.8.
I used vagrant to test and it seems to be working fine
I would like to see some spec tests for this.
@dcrissman , sorry, I thought it had already rspec tests. Fixed
This PR have enhancement over the constraints and the ordering .It also completed the other alternatives missed to be configured and added the installation of them in case they are missed.
There is an pending issue that I couldn't put the assign of a variable in the right order (which can really impact us)
Also, it might be desired to use sinle quote all over the paths, even that theses paths doesn't include any space.
Related to issue https://github.com/lightblue-platform/lightblue-puppet/issues/44