Feature #915

Add 'options' support to type/provider relationship

Added by Luke Kanies almost 3 years ago. Updated 1 day ago.

Status:Accepted Start:
Priority:Normal Due date:
Assignee:- % Done:

0%

Category:RAL
Target version:unplanned
Affected version:0.24.7 Branch:
Keywords:
Votes: 3

Description

Some providers (notably packages) are configurable, and it is often important to be able to use that configuration to get specific behaviour from the providers.

We should add an ‘option’ hook to the providers, akin to the current ‘feature’ hook.


Related issues

related to Puppet - Feature #2247: enablerepo and disablerepo for yum type Accepted 05/12/2009
related to Puppet - Feature #556: apt provider should support --allow-unauthenticated option Rejected
related to Puppet - Feature #1766: Control of recommends installation with aptitude provider Accepted 11/20/2008
duplicated by Puppet - Feature #2325: Apt provider should allow passing of arbitrary configurat... Duplicate 06/04/2009

History

Updated by Redmine Admin about 2 years ago

  • Status changed from 1 to Accepted

Updated by Luke Kanies about 2 years ago

  • Priority changed from High to Normal
  • Affected version set to 0.24.4

Updated by James Turnbull over 1 year ago

  • Affected version changed from 0.24.4 to 0.24.7

Updated by Brandon Evans over 1 year ago

Another example of when being able to modify provider options would be when one wants to install a package from a repo that is disabled by default. For example, installing a package from rpmforge when rpmforge is disabled by default on my servers.

when running from the command line I can simply run:

yum —enablerepo=rpmforge install PACKAGE

however to do this in puppet I need o use an exec, or as ‘jamesturnbull’ suggested:

[3:52pm] package has a require and a notify metaparam [3:52pm] the requireis linked to a yumrepo resource that enables rpmforge [3:52pm] the notify is linked to a yumrepo resource that disables it

Both solutions work however having to use exec seems like a wast of the package{} command. Temporarily enabling the repo then triggering another resource is flawed too. Yums locking should prevent this, but what if someone on the server is doing a ‘yum update httpd’ while puppet has switched the rpmforge repo to enabled?

Updated by James Turnbull about 1 year ago

  • Assignee deleted (Puppet Community)

Also available in: Atom PDF