In regard to: [Puppet Users] Install RPM package via puppet, Sixthmoon said...:

I have the package added to an internal yum repo. OS is Centos 5.4. Puppet
version is 2.6.2-1. The module is "utilities". This is a working production
environment. (Person who set it no longer around) As a verification item to
note, I have added a custom fact to the "utilities" module and it correctly
being picked up by the test node.

I have added the following to init.pp

class utilities {

   package { "iftop":
             ensure => "present",
       source =>
'http://yum.repo.internal/misc/iftop-0.17-1.el5.rf.x86_64.rpm'
           }
}

        package { 'iftop':
                ensure => present,
                require => Yumrepo['your-repo-name-here'],
        }

You should also have a

        yumrepo {'your-repo-name-here':
                baseurl => 
'http://your.host.here/repo/CentOS/$releasever/$basearch/',
        enabled => 1,
        descr   => 'whatever',
        metadata_expire => '300',
        }

somewhere in your catalog.

You've already done the parts that a lot of people seem to want to skip;
specifically packaging the software and creating a local repo with the
software in it.  You just need to define your repo to puppet and then
use a very standard "package" resource to make it present.

Note the yumrepo resource type supports a lot more attributes, which you
may wish to investigate.

Tim
--
Tim Mooney                                             tim.moo...@ndsu.edu
Enterprise Computing & Infrastructure                  701-231-1076 (Voice)
Room 242-J6, IACC Building                             701-231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164

--
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.

Reply via email to