Hi,

You can use a yum makecache exec and require it in your php package section (or 
whatever relies on that repo). 

I've previously put all my repo calls in a 'stage' that ran before 'main' stage 
(see puppet docs for details). That worked well for local repo mirrors - was a 
slow down for others.

Cheers,
Den

On 08/01/2013, at 14:33, goo...@reetstreet.com wrote:

> On Centos 6.3, I have attempted to upgrade to php 5.4 using the following:
> 
>     yumrepo { "epel-repo":
>         baseurl => "http://download.fedoraproject.org/pub/epel/6/\$basearch";,
>         descr => "Epel Repo",
>         enabled => 1,
>         gpgcheck => 0,
>     }
>     yumrepo   { "remi-repo":
>         baseurl => 
> "http://rpms.famillecollet.com/enterprise/6/remi/\$basearch/";,
>         descr => "remi repo",
>         enabled => 1,
>         gpgcheck => 0,
>         require => Yumrepo["epel-repo"],
>     }
>     package { 'php':
>         ensure => latest,
>         require => [ Yumrepo["remi-repo"] ],
>     }
> 
> This actually works fine, but only if I apply the manifest twice.  It seems 
> that the first time it runs, the Remi repo has not been installed, so Puppet 
> decides that the Package php statement ensure => latest is in fact 
> up-to-date, so it does not actually try to update php.  (php 5.3.3 is 
> installed from the default repository; Remi makes php 5.4 available.) On the 
> second run, Remi is installed, and Puppet correctly notices that php needs to 
> be updated.
> 
> Is there any way I can get the php package rule to update php on the first 
> run?
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Puppet Users" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/puppet-users/-/oHjxcqEowX4J.
> 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.

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