Issue #3809 has been updated by Matteo Cerutti.
James, No I do not get any error messages, it just does not do what it is supposed to. Perhaps you can try it yourself, the reason why I'd like to store my keys into virtual resources is the fact that by overriding the user (when realizing the resource) I can distribute them among users however I want. In the example above in the authorized_keys for userA I should have both us...@hosta and us...@hostb. In userB I should just have us...@hostb. Mind that the problem happens just in a situation like the above, when realizing the same resource (us...@hostb) more than ONCE on the SAME node. In fact just one will get realized and the other not. I don't know if I can be of any help by providing any more information. Thanks. ---------------------------------------- Bug #3809: Problem with virtual resources http://projects.puppetlabs.com/issues/3809 Author: Matteo Cerutti Status: Needs more information Priority: Normal Assigned to: Category: Target version: Affected version: 0.25.4 Keywords: Branch: Hi, I'm trying to manage ssh authorized keys through the use of virtual resources. <pre> class ssh::keys { @ssh_authorized_key {"us...@hosta": key => "..."; "us...@hostb": key => "..."; "us...@hostc": key => "..."; } } </pre> Now i set up a few user classes which I will include in a node definition. I realize inside the user classes the ssh keys I am interested in importing into their authorized_keys file, this happens by overriding the user parameter. <pre> class users::testA { Ssh_authorized_key <| title == "us...@hosta" |> { user => "testA" } Ssh_authorized_key <| title == "us...@hostb" |> { user => "testA" } } class users::testB { Ssh_authorized_key <| title == "us...@hostb" |> { user => "testB" } } </pre> # Now I include the user classes. <pre> node test { include users::testA include users::testB } </pre> Note that the is not connection between usernames and hostnames. This setup works but apparently I cannot realize the same resource twice on the same machine. Let me explain, for the user testA <pre> Ssh_authorized_key <| title == "us...@hostb" |> { user => "testA" } </pre> this will be realized but the second virtual resource for the user testB does not seem to the realized as I cannot see anything is the authorized_keys. This is true for the same resource, if I comment one or the other out then the one left out will be realized. Any idea? Thanks. -- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://projects.puppetlabs.com/my/account -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" 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-bugs?hl=en.
