hi All,

I'm a bit new to puppet. Is there a mailing list for puppet beginners?:)


I have a service module called postfix, which defines file in a class:

    file {
    '/etc/postfix/main.cf':
        owner => "root",
        group => "root",
        mode  => 644,
        content => template('postfix/etc/postfix/main.cf.erb'),
        notify => Service['postfix'],
        require => Package['postfix']
    }

This is included in the base node which is inherited by all nodes.

For one node I want to change the configuration:

node "jay.foo.com" inherits nodes_base {
    include jay
}


jay (node specific) module:

class jay inherits postfix {
    File ["/etc/postfix/main.cf"] {
        content => template('jay/etc/postfix/main.cf.erb')
    }

}


This works fine.

However I'd like to use this:

class jay {
    include jay::postfix
}

class jay::postfix inherits postfix {
    File ["/etc/postfix/main.cf"] {
        content => template('jay/etc/postfix/main.cf.erb')
    }

}

#  puppet agent -t --noop
err: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find scope for jay::postfix at /etc/puppet/nodes/jay/manifests/init.pp:2 on node jay.foo.com
warning: Not using cache on failed catalog
err: Could not retrieve catalog; skipping run



Or this:

node "jay.foo.com" inherits nodes_base {
#   include jay
    File ["/etc/postfix/main.cf"] {
        content => template('jay/etc/postfix/main.cf.erb')
    }

}


# puppet agent -t --noop
err: Could not retrieve catalog from remote server: Error 400 on SERVER: Only subclasses can override parameters at /etc/puppet/manifests/nodes.pp:24 on node jay.foo.com
warning: Not using cache on failed catalog
err: Could not retrieve catalog; skipping run
root@jay:~#


What's wrongm, what do I miss?


Thanks,
tamas

--
You received this message because you are subscribed to the Google Groups "Puppet 
Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to