You will need to import your jdk class file in site.pp

Something like this:

import "jdk.pp"

At the top of site.pp

Cheers,
Josh

On Sunday, April 21, 2013 9:18:36 AM UTC-4, max.bri...@gmail.com wrote:
>
> Hi,
>
> Trying to get some understanding on how code should be structured in 
> Puppet. I have a class oracle_java defined to deploy the Java virtual 
> machine on the agents  (basically copy of 
> http://log.scalemotion.com/2013/04/oracle-java-under-linux-with-puppet.html). 
> It works fine if i copy the body of the class (omitting the class 
> declaration) within site.pp. But that's no way to do business as you may 
> presume.
>
> Now, I put the class under /etc/puppet/manifests/jdk.pp and change site.pp 
> into:
>
> node default{
>   include jdk
> }
>
> Unfortunately, this doesn't work. I keep getting the following error 
> message from the agent:
>
> Could not retrieve catalog from remote server: Error 400 on SERVER: Could 
> not find class jdk for 
> ec2-52-221-193-75.compute-1.amazonaws.com-c1421f15-ac06-c6ab-6b5d-95f238bf27c7.
>
> Is there a way to reference a class in site.pp without creating a module?
>
> Thanks,
> Max.
>

-- 
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+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@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.


Reply via email to