On Wed, Nov 24, 2010 at 9:32 AM, sanjiv.singh
<[email protected]> wrote:
> hi all,
>
> I had defined a module like this ..
>
> modulea
> ---------- ---manifest
> ---------------------- ---myclassa.pp
> ================
> # i have declared number
> defines..like
> define defile1
> {
> .......................
> }
> define defile2
> {
> .......................
> }
>
> =================
> moduleb
> ---------- ---manifest
> ---------------------- ---myclassb.pp
> ================
> # where i want to use those
> defines..of module <modulea>
>
>
>
> =================
>
> can anyone tell me ..
> How can I invoke defines of module <modulea> in module <moduleb>'s
> manifest ?
> and
> Plz give me link of document reference for most information .
You should instead use the autoloader to find the definitions.
Hopefully this example will help.
# File at $modulepath/mymodule/manifests/init.pp
class mymodule { ... }
# File at $modulepath/mymodule/manifests/mydefine.pp
define mymodule::mydefine(..) { ... }
# File anywhere else, outside the mymodule scope.
mymodule::mydefine { ... }
Does that make sense? Because your defined type is
"mymodule::mydefine", the autoloader will look for that definition in
$modulepath/mymodule/manifests/mydefine.pp
>
> --
> Sanjiv Singh (iLabs)
> Impetus Infotech India.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" 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-users?hl=en.
>
>
--
Nigel Kersten - Puppet Labs - http://www.puppetlabs.com
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" 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-users?hl=en.