Re: [Puppet Users] stages examples/advices

2012-10-22 Thread Danie van Zyl
My 2cents, Why not use the stdlib that puppet provides. It contains the following stage presets, class stdlib::stages { stage { 'setup': before => Stage['main'] } stage { 'runtime': require => Stage['main'] } -> stage { 'setup_infra': } -> stage { 'deploy_infra': } -> stage { 'setup_

Re: [Puppet Users] stages examples/advices

2010-10-20 Thread David Schmitt
On 10/18/2010 6:14 PM, Hunter Haugen wrote: so you could do this: class orden { stage { [ 'repos', 'os', 'gLite', 'post' ]: } Stage['repos'] -> Stage['os'] -> Stage['main'] -> Stage['gLite'] -> Stage['post'] } A style question: wouldn't it be preferable to write it like this: class

Re: [Puppet Users] stages examples/advices

2010-10-18 Thread Arnau Bria
On Mon, 18 Oct 2010 09:14:09 -0700 Hunter Haugen wrote: Hi, [...] > In your working example you define the classes and then enforce > ordering at the same time. The new syntax references the stages but > doesn't actually define them, so you could do this: > class orden { > stage { [ 'repos', '

Re: [Puppet Users] stages examples/advices

2010-10-18 Thread Hunter Haugen
> 3.-) Stage order. > > but when applying new syntax: > > class orden { >        Stage['repos'] -> Stage['os'] -> Stage['main'] -> Stage['gLite'] -> > Stage['post'] > } In your working example you define the classes and then enforce ordering at the same time. The new syntax references the stages

Re: [Puppet Users] stages examples/advices

2010-10-15 Thread Arnau Bria
On Fri, 15 Oct 2010 17:54:17 +0530 Mohit Chawla wrote: > On Fri, Oct 15, 2010 at 4:46 PM, Bruce Richardson > wrote: > > > On Fri, Oct 15, 2010 at 12:19:36PM +0200, Arnau Bria wrote: > > > 1.-) Stage vs require Class. May we say that stages are groups of > > > class requires? So a simple/basic exa

Re: [Puppet Users] stages examples/advices

2010-10-15 Thread Mohit Chawla
On Fri, Oct 15, 2010 at 4:46 PM, Bruce Richardson wrote: > On Fri, Oct 15, 2010 at 12:19:36PM +0200, Arnau Bria wrote: > > 1.-) Stage vs require Class. May we say that stages are groups of class > > requires? So a simple/basic example: > > > > class A { > > require class B > > } > > > > class B{ >

Re: [Puppet Users] stages examples/advices

2010-10-15 Thread Bruce Richardson
On Fri, Oct 15, 2010 at 12:19:36PM +0200, Arnau Bria wrote: > 1.-) Stage vs require Class. May we say that stages are groups of class > requires? So a simple/basic example: > > class A { > require class B > } > > class B{ > require class C > } > > Is like defining : > > Stage[pre] -> Stage[main