Issue #6907 has been updated by Stefan Schulte.
you should be able to declare your command with the `optional_commands` method instead of the `commands` method. `optional_commands` does not an `confine :exists => your_command` so your provider should not fail and work in the first puppet run. While I haven't tried it myself I expect two problems * your provider may be picked even if the package that is supposed to provide the needed binaries (in your case git) is not installed (no package resource in the manifest, failed installation or missing dependencies). This may be a bad idea if you have more than one provider for your type and another provider would have been functional. * you may get a lot of failures if you do a `noop` run because now the binaries are definitely absent. Besides the two possibe solutions I mentioned earlier: What about just skipping resources that do not have a suitable provider (instead of failure)? ---------------------------------------- Feature #6907: Ensure providers can be used in the same puppet run that their prerequisites are delivered in https://projects.puppetlabs.com/issues/6907 Author: Nigel Kersten Status: Accepted Priority: Urgent Assignee: Category: Target version: 2.7.x Affected Puppet version: Keywords: Branch: This is possibly more accurately described as a collection of bug fixes, as we've aimed to fix this several times, however I'm characterizing this as a feature, and we're going to associate related bugs with it. Essentially we want to be able to use a provider in the same run that it's prerequisites (like :commands and paths) are delivered in. You should not have to run puppet twice to use a provider. We're aiming this at 2.6.x initially, but if it turns out that we need significant plumbing work to make this happen, we are re-targeting at Statler. -- 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.
