On Thu, Aug 9, 2012 at 2:00 PM, Denmat <tu2bg...@gmail.com> wrote:
>
>
> On 10/08/2012, at 3:20, Nigel Kersten <ni...@puppetlabs.com> wrote:
>
>> On Thu, Aug 9, 2012 at 10:10 AM, Douglas Garstang
>> <doug.garst...@gmail.com> wrote:
>>> I'm on Ubuntu, and I wanted to always have 'apt-get update' run before
>>> attempting to install packages, so I put this in my top level site.pp
>>> file:
>>>
>>> exec {
>>>    'refresh-repos':
>>>        command => '/usr/bin/apt-get update';
>>> }
>>>
>>> Package {
>>>    require => Exec['refresh-repos']
>>> }
>>>
>>> However, that causes a nasty cyclic dependency error. I really HATE
>>> those because the error message makes it impossible to interpret
>>> what's actually going on.
>>>
>>> How can I do this without the awful cyclic error messages?
>>
>> What version of Puppet are you on? Can you paste or link to the error
>> message itself so we can actually tell what the dependency cycle is?
>>
> I have used stages to handle this sort of thing. Setting up a repo stage to 
> refresh repos before the main stage.
>
> http://docs.puppetlabs.com/references/stable/metaparameter.html#stage

That's true, but stages aren't required to make this work.

It's impossible for us to tell why there is a dependency cycle here
without more info.

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