Issue #5349 has been updated by Steve Snodgrass.
I think I just ran into this problem too. My case is similar to Dan's - I'm
just trying to get my yum repos to install before everything else, but I'm
doing it in a base class that all my nodes inherit. Example:
stage { 'pre':
before => Stage['main'],
}
node base {
class { 'yum::repos': stage => 'pre' }
include ssh
...more junk elided...
}
node foobar inherits base {
...
}
This generates a huge dependency cycle. :(
----------------------------------------
Bug #5349: Class inheritance and stages act weirdly
https://projects.puppetlabs.com/issues/5349
Author: R.I. Pienaar
Status: Needs Decision
Priority: Normal
Assignee: Nigel Kersten
Category:
Target version:
Affected Puppet version: 2.6.3
Keywords:
Branch:
Given the code:
<pre>
stage { "first": before => Stage[main] }
class foo {
package{"zsh":
ensure => present
}
}
class bar inherits foo {
notify{"/usr/bin/cowsay 'hello world'":
require => Package["zsh"]
}
}
class{"bar": stage => "first"}
</pre>
This produce
<pre>
err: Could not apply complete catalog: Found dependency cycles in the following
relationships: Package[zsh] => Notify[/usr/bin/cowsay 'hello world'],
Notify[/usr/bin/cowsay 'hello world'] => Package[zsh], Notify[/usr/bin/cowsay
'hello world'] => Class[main]; try using the '--graph' option and open the
'.dot' files in OmniGraffle or GraphViz
</pre>
If I add:
<pre>
class{"foo": stage => "first"}
</pre>
It sorts itself out.
I am not sure what the correct behavior would be, at first I think we should
just pull the inherited class into the 'first' stage as well but I can imagine
that causing weird issues too?
--
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://projects.puppetlabs.com/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.