Issue #2062 has been updated by jbooth.
>From epel-release's "/etc/yum.repo.d/epel.repo", modified with the puppet >config below: <pre> [epel] name=Extra Packages for Enterprise Linux 5 - $basearch #baseurl=http://download.fedoraproject.org/pub/epel/5/$basearch failovermethod=priority enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL baseurl=http://my.server/pub/monthly/epel/5/$basearch [epel-debuginfo] name=Extra Packages for Enterprise Linux 5 - $basearch - Debug #baseurl=http://download.fedoraproject.org/pub/epel/5/$basearch/debug failovermethod=priority enabled=0 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1 baseurl=http://my.server/pub/monthly/epel/5/$basearch/debug [epel-source] name=Extra Packages for Enterprise Linux 5 - $basearch - Source #baseurl=http://download.fedoraproject.org/pub/epel/5/SRPMS failovermethod=priority enabled=0 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1 baseurl=http://my.server/pub/monthly/epel/5/SRPMS </pre> My puppet definitions: <pre> file { "/etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL": owner => root, group => root, mode => 0444, source => "puppet://$servername/yum/RPM-GPG-KEY-EPEL"; } Yumrepo { mirrorlist => absent, enabled => 0, gpgcheck => 1, gpgkey => "file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL", require => File["/etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL"] } $server = "http://my.server/pub/monthly" # Note that EPEL hardcodes the RHEL 3/4/5 version, so $operatingsystemrelease isn't escaped here! yumrepo { "epel": enabled => 1, descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - \$basearch", baseurl => "$server/epel/$operatingsystemrelease/\$basearch"; "epel-debuginfo": descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - \$basearch - Debug", baseurl => "$server/epel/$operatingsystemrelease/\$basearch/debug"; "epel-source": descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - \$basearch - Source", baseurl => "$server/epel/$operatingsystemrelease/SRPMS"; "epel-testing": descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - Testing - \$basearch", baseurl => "$server/epel/testing/$operatingsystemrelease/\$basearch"; "epel-testing-debuginfo": descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - Testing - \$basearch - Debug", baseurl => "$server/epel/testing/$operatingsystemrelease/\$basearch/debug"; "epel-testing-source": descr => "Extra Packages for Enterprise Linux $operatingsystemrelease - Testing - \$basearch - Source", baseurl => "$server/epel/testing/$operatingsystemrelease/SRPMS"; } </pre> As I said, it works for me. Things only get confused if I puppet first and then install epel-release, at which point it doesn't create epel.repo, it creates epel.repo.rpmnew instead (config file already exists, so rpm doesn't clobber it). It is possible this is a 0.24.7-specific bug because my RHEL5 box only has 0.24.6. You might need the 'descr' lines set and matching to make it work? I hadn't tested without them. ---------------------------------------- Bug #2062: yumrepo resource does not support multiple repos per file http://projects.reductivelabs.com/issues/2062 Author: TrevorHemsley Status: Accepted Priority: Low Assigned to: community Category: yumrepo Target version: unplanned Complexity: Unknown Affected version: 0.24.7 Keywords: Many of the files in /etc/yum.repos.d on Centos/Redhat contain multiple repos within a single file. Using the yumrepo resource it is not possible to manage the contents of these files. Example: Cobbler installs a file called /etc/yum.repos.d/cobbler-config.repo which contains <pre> name=core-0 baseurl=http://your.url:80/cobbler/ks_mirror/Centos5.2-i386 enabled=1 gpgcheck=1 [Centos5-x86_64-UPDATES] name=Centos5-x86_64-UPDATES baseurl=http://your.url:80/cobbler/repo_mirror/Centos5-i386-UPDATES enabled=1 gpgcheck=1 </pre> Defining a yumrepo {"core-0":} allows you to manage the first of these repos inside the file but if you attempt to define a yumrepo {"Centos5-x86_64-UPDATES": } resource then puppet will create a new file containing a duplicate definition. -- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://reductivelabs.com/redmine/my/account --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/puppet-bugs?hl=en -~----------~----~----~----~------~----~------~--~---
