Re: [Puppet Users] Stages and concat

103 views
Skip to first unread message

R.I.Pienaar

unread,
May 30, 2013, 11:39:27 AM5/30/13
to puppet...@googlegroups.com


----- Original Message -----
> From: "Mario Abajo" <mario...@gmail.com>
> To: puppet...@googlegroups.com
> Sent: Thursday, May 30, 2013 3:28:23 AM
> Subject: [Puppet Users] Stages and concat
>
> Hi!,
> I'm working on a module that's being called in a different stage than main,
> a previous one. THis modules is composed of various "defines" and use the
> concat module inside. My question is ¿may i use concat different stages? i
> was having cycle problems because of the class concat::setup.
> Is this a correct form of doing this? or is there a better one?

stages is generally just bad and you should find better ways to do what you
want, maybe using chaining or something else.

concat cant work with stages

>
> Thanks in advance
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users...@googlegroups.com.
> To post to this group, send email to puppet...@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

jcbollinger

unread,
Jun 4, 2013, 9:43:29 AM6/4/13
to puppet...@googlegroups.com

On Thursday, May 30, 2013 10:39:27 AM UTC-5, R.I. Pienaar wrote:

stages is generally just bad and you should find better ways to do what you
want, maybe using chaining or something else.



+1

Really.  Stages are a very blunt tool.  If you try to do anything very complicated with them then you are likely to run into difficulties.  Although such issues are often resolvable without giving up on stages, they make more work for you, eating into and maybe even overcoming any gains you might have been expecting from use of stages.

If you stick to simple uses of stages, on the other hand, then you probably don't have any potential gains over Puppet's sharper, more precise alternatives in the first place.


John

Jakov Sosic

unread,
Jun 7, 2013, 5:59:17 PM6/7/13
to puppet...@googlegroups.com
On 06/04/2013 03:43 PM, jcbollinger wrote:

> If you stick to simple uses of stages, on the other hand, then you
> probably don't have any potential gains over Puppet's sharper, more
> precise alternatives in the first place.

I use stage (before main) for setting up yum repositories. That's
because I want to avoid making dependencies between modules such as
'cobbler' and some specific repository (for example EPEL).

That way my modules are transferable between Fedora and RHEL/CentOS. So,
stages serve me pretty well.

Idea is to have all yum repositories set up, before any of the package
resources gets applied on system.


Is there a better way to achieve this?


--
Jakov Sosic
www.srce.unizg.hr

James Kyle

unread,
Jul 4, 2013, 11:53:08 AM7/4/13
to puppet...@googlegroups.com
I know this is old, but ran into it due to some concat dep cycle errors I had. 

But the way you can do this without stages is with collections. If you're using the apt module, you'd

Class['myrepositories'] -> Apt::Source<| |>
Reply all
Reply to author
Forward
0 new messages