On Tue, Jul 22, 2014 at 9:16 AM, <[email protected]> wrote:

> Hi Trey,
>
> I'm using Hiera and changed now:
>
>     p_drbd_jira:
>       primitive_class:  ocf
>       primitive_type:   drbd
>       provided_by:      linbit
>       parameters:
>         drbd_resource:  jira
>       operations:
>         monitor:
>           - {interval:  '10s', role:  'Master'}
>           - {interval:  '20s', role:  'Slave'}
>
> puppet agent -t --debug:
> Error:
> /Stage[main]/H24-corosync::Config/H24-corosync::Resource[primitive]/Cs_primitive[p_drbd_jira]:
> Could not evaluate: undefined method `each_pair' for
> #<Array:0x000000037c9a68>
>
> My class to get the data from Hiera:
>
> class h24-corosync::config {
>
>     $config = hiera('h24-corosync::config',
>         {
>             property => {},
>             primitive => {},
>             colocation => {},
>             order => {},
>             group => {}
>         })
>     h24-corosync::resource { 'property':
>         params => $config[property],
>         defaults => {ensure => present}
>     } ->
>     h24-corosync::resource { 'primitive':
>         params => $config[primitive],
>         #defaults => {operations => {monitor => { 'interval' => '30s' }}}
>     } ->
>     h24-corosync::resource { 'group':
>         params => $config[group]
>     } ->
>     h24-corosync::resource { 'colocation':
>         params => $config[colocation]
>     } ->
>     h24-corosync::resource { 'order':
>         params => $config[order]
>     }
>
> }
>
> Which code do I have to change?
>

You will have to update the provider code at
https://github.com/puppetlabs/puppetlabs-corosync/tree/master/lib/puppet/provider/cs_primitive
to support array values of the cs_primitive operations hash. If you take
the time to do this and send a pull request on github, that would be great
:).


>
> Regards - Willi
>
> --
> 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 [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/00d52bf6-835d-47ca-9e71-6b569f78d89b%40googlegroups.com
> <https://groups.google.com/d/msgid/puppet-users/00d52bf6-835d-47ca-9e71-6b569f78d89b%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAJaQvGBfL_sSZXDNpp%3DRc33udax5ynh7AOShbdFoez%3DgetroYw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to