Closed zeroecco closed 10 years ago
thanks @zeroecco I'm gonna test it and merge.
Not sure why Travis failed, something to due with credentials...
that's normal with pull requests.. the change needs to come from me for it to validate the credentials, not sure if there is a way to avoid it since I use the forge plugin for travis.
I'm going to review #32 and also add this to the tests during the merge.
Merged this change on my branch for testing: https://github.com/fsalum/puppet-redis/tree/zxjinn-master
@fsalum so looking for a way to specify the version of Redis, looks like the PR request above addresses this?
@dhonig yes and no.. it uses the 'redis-cli --version' to find and re-set the version so we can lookup and apply the correct redis.conf.. if it finds 2.4.10 it sets redis_version == 2.4.x, for 2.8.8 to 2.8.x and so on for all other releases.
Lol..happy to help out once I'm not a puppet novice, for now I just want to be able to class{ redis: version => '2.8.x' {
and have something work, is that supported?
@dhonig not really, the current module installs the standard redis version coming from your OS repository. Per example CentOS using epel will install redis 2.4, Debian Precise redis 2.2, different flavors of ubuntu installs 2.4, 2.6 or 2.8. :)
For you to specify something like you want I would need to grab the redis .tar.gz and compile it, install init scripts, etc. Not going that route for now.
Makes perfect sense. This is exactly why my current dev setup with puppet takes 20 minutes. Understood.
Building on dhonig's comment (and this could probably be a separate issue but still...): If I'm on CentOS using the Remi repo which offers redis 2.8.8, using this class with its defaults should install redis 2.8.8 right? Being able to select a specific version is fairly important in heterogeneous environments, especially considering that we can't use this class and declare package { 'redis' : ensure => 2.8.8 }. Wouldn't expect this module to compile the application but IMO it seems reasonable to include a version parameter.
If you don't specify a version yum always install the latest version from the repository, if all repositories have the same priority. So in your case it would install 2.8.8.
However the class allows you to specify a version and it will work if you have it on the repository, by default it is 'present'.
class { redis:
package_ensure => '2.8.8',
}
Ahh OK. That's the bit I was missing. Thanks!
Closing this as work is being done via https://github.com/fsalum/puppet-redis/pull/32
Added logic via a puppet fact to parse the redis config intelligently for support of 2.4 through 2.8 on centos