I disliked all the dependencies that the -lsb package pulled onto my servers, like CUPS and X. So I just created a custom fact with the code that has been used since el3 to determine a release:
Facter.add("release") do setcode do %x{cat /etc/redhat-release | awk -Frelease {'print $2'} | awk {'print $1'} | awk -F. {'print $1'}}.chomp end end Not any more elegant than the /^5/ matching, but I am happy with it. Jim Goddard On Feb 3, 9:29 am, Ramin K <ramin.khat...@gmail.com> wrote: > You'll need to add the redhat-lsb package to your kickstart system and/ > or just install it on your current systems. That's the package facter > uses to determine the lsb facts. > > On Feb 3, 8:57 am, Dick Davies <rasput...@hellooperator.net> wrote: > > > > > > > > > Just started a rollout of centos 6.x across our Puppet deployment > > (100-odd servers). > > > what fact would people suggest I use to distinguish 5.x from 6.x > > (quite a lot of subsystems are different between major releases)? > > > lsb* facts don't seem to be present on centos 6 - is this an EPEL bug, > > or have they > > just been removed in Facter? > > > Thanks! -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.