summaryrefslogtreecommitdiffstats
path: root/lib/puppet/provider
Commit message (Collapse)AuthorAgeFilesLines
* Fixed the return types were valid, and removed the copy paste error with the ↵Bryan Kearney2010-02-171-4/+4
| | | | exception logic
* Resolving conflicts with ???Markus Roberts2010-02-171-1/+1
| | | | This actually fixes a bug in the patch, not a conflict per se, but it was small and this was the easiest way to fix it.
* Add AIX package management support (installp&nim)Andrew Forgue2010-02-172-0/+173
| | | | | | | | | | This patch adds support for the native AIX package manager. It allows installation from either the name of an lpp_source (if you have a NIM environment configured, or from a directory containing .bff files. Signed-off-by: Andrew Forgue <andrew.forgue@gmail.com>
* Fix #3167 Duplicate constant warnings in dpkg.rbJesse Wolfe2010-02-172-8/+8
| | | | | | | | | | | | | | There's a limitation in Ruby 1.8.x that makes constants behave differently than developers seem to expect: Constants defined inside a do/end block do not get inserted into the namespace of 'self', they instead go into the toplevel (Object) namespace. These providers exhibit bugs since they use constants with the same name in the same namespace. Other providers and other dynamically generated classes using constants without an explicit namespace should be considered to have a code smell. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
* Merge branch '0.25.x'Markus Roberts2010-02-096-17/+36
|\ | | | | | | | | | | | | | | | | | | Conflicts: lib/puppet/agent.rb lib/puppet/application/puppet.rb lib/puppet/configurer.rb man/man5/puppet.conf.5 spec/integration/defaults.rb spec/unit/configurer.rb
| * Fix for #2327, check the return types from augeas and fail where appropriateBryan Kearney2010-02-011-4/+10
| |
| * 2047: Add a not_include into matchBryan Kearney2010-02-011-0/+4
| |
| * Fix for #3035 (redhat services use init for source)Markus Roberts2010-01-301-1/+1
| | | | | | | | | | | | | | Redhat services generated a slew of errors because they "duplicated" the same services from the init provider on which the redhat provider is based (cf yum). Declaring the source suppresses these erroneous errors.
| * Fix for #3085 (user_role_add pulls from same source as useradd)Markus Roberts2010-01-301-1/+1
| |
| * Partial reversion of patch for #3088 to fix #3104 (Exception misreported)Markus Roberts2010-01-241-2/+2
| | | | | | | | | | | | | | In my patch for #3088 I made a erroneous assumption about the ruby exception hierarchy and thus missed the fact that Timeout::error descends from both SignalError and Interrupt. This is a partial reversion of the patch for #3088 to let these through so that more useful error messages can be produced.
| * Fix for #3088 (catching Exception also traps SystemExit)Markus Roberts2010-01-241-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | Changing rescues from the default to Exception (to catch errors that don't descend from StandardError) had the unintended consequence of catching (and suppressing) SystemExit. This patch restores the behavior of by reraising the exception. Of the other exceptions that fall through the same crack (NoMemoryError, SignalException, LoadError, Interrupt, NotImplementedError, and ScriptError) this patch also reraises NoMemoryError, SignalException, and Interrupt in the same way and leaves the rest captured.
| * Fix for #3093 (also need to be able to call pkgget_with_cat on class)Markus Roberts2010-01-221-2/+2
| | | | | | | | Fixed to deal with scopig issues.
| * Fix for #3075 (sshkey host_aliases ignored)Markus Roberts2010-01-151-5/+5
| | | | | | | | | | | | | | In the alias --> host_aliases conversion, I overlooked parsed file provider for sshkeys. Now with tests.
| * Revert "Fix #2845 Cron entries using "special" parameter lose their title ↵James Turnbull2010-01-141-4/+9
| | | | | | | | | | | | | | | | when changed" This reverts commit c99f394bf8c10d13f3fa7d3ab7ab43ecf454c081. The fix broke cron jobs in 0.25.3 and was reverted for the 0.25.4 release.
* | First shot at the OpenSolaris pkg(5) providerMartin Englund2010-01-271-0/+114
| |
* | Merge branch '0.25.x'James Turnbull2010-01-138-36/+59
|\| | | | | | | | | | | Conflicts: lib/puppet/ssl/host.rb spec/spec_helper.rb
| * Fix #1464 Mount complains about missing fieldsJesse Wolfe2010-01-121-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This family of errors could appear because Puppet parses every line in fstab into resources, even lines that are not specifically managed by Puppet, and fstab files are much more permissive than Puppet in what constitutes a valid mount. This change makes several fields optional that were previously mandatory. Also, it ignores lines in fstab that have fewer than the required number of parameters. Includes a more readable regex than the previous patch. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * Fix #2845 Cron entries using "special" parameter lose their title when changedJesse Wolfe2010-01-121-9/+4
| | | | | | | | | | | | | | Merged the "freebsd_special" pattern into the other crontab records, since its definition was incomplete Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * Fix #2887 'service' tests paths too earlyJesse Wolfe2010-01-081-2/+18
| | | | | | | | | | | | | | | | | | The 'service' type was testing to see if init script directories exist too early, causing failures if you expected to be able to create those directories via puppet. This patch moves that logic into the 'init' provider. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * Fix for #2999 (absent package handling on solaris)Markus Roberts2010-01-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | The fix for #2940 resulted in a behavior change that could be seen as a bug. This was consistent with many of the other providers (see #3000) but was not the desired behavior. This patch enhances the patch for #2940 to return {:ensure => :absent} as the present state in the case that the failure was due to the package not being installed (as opposed to a source/index failure, etc.). The other possibility would have been {:ensure => :purged}.
| * fix #2987 - check correct hash entryPeter Meier2009-12-251-1/+1
| | | | | | | | It looks like something got lost during transition to host_aliases.
| * Making provider/host/parser.rb compatible with host_aliasesMarkus Roberts2009-12-231-8/+8
| | | | | | | | | | When I changed the alias property of hosts to host_aliases I missed these changes in the parsed file provider.
| * Fix for #2940 (propogating nil rather than reporting the error)Markus Roberts2009-12-231-3/+4
| |
| * Fix for #887 (safely setting pager to cat for blastwave)Markus Roberts2009-12-151-6/+7
| | | | | | | | This is Luke's suggested fix, from the ticket.
| * Fix for #2900 (rug output parsing too specific)Markus Roberts2009-12-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Andrew Forgue's suggested patch; changes the regular expression to accept any non-space characters, non-vertical bar characters in a version "number". Examples v | SLES10-SP1-Updates | | resmgr | 0.9.8_SVNr75-18.9 | x86_64 v | SLES10-SP1-Updates | | wireless-tools | 28pre13-22.16.2 | x86_64 Signed-off-by: Markus Roberts <Markus@reality.com>
| * Fixing 2849 puppet changes sshkey alias every run if it is blankJesse Wolfe2009-12-091-5/+3
| | | | | | | | | | | | | | | | Puppet was mis-parsing sshkey aliases when the last alias is an empty string. This is due to the counter-intuitive behavior of Ruby's String#split. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * Fixed #2798 - Correct issue with crontab provider on AIXAndrew Forgue2009-12-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Clean up AIX crontab type: - The return "" if output.include?(...) prevented the raise from ever being reached. - Ensure the temp file is deleted after feeding it to cron. - Prevent dumping of the new crontab to STDOUT. Signed-off-by: Andrew Forgue <andrew.forgue@gmail.com>
* | Merge branch '0.25.x'Luke Kanies2009-12-2110-39/+45
|\| | | | | | | | | | | | | | | Conflicts: lib/puppet/agent.rb lib/puppet/application/puppetd.rb lib/puppet/parser/ast/leaf.rb lib/puppet/util/rdoc/parser.rb
| * fix regex for non-installed packagesBenedikt Böhm2009-11-231-1/+1
| |
| * Fixing 2812 authorized_keys without comments failJesse Wolfe2009-11-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is technically a duplicate of #1531, I think this change prevents the problem that appears in #2812, without touching the underlying issues of #1531. ssh_authorized_key was failing on keys in ~/.ssh/authorized_keys that lack a comment field - it would generate a Ssh_authorized_key resource with the name set to nil, which raises "ArgumentError: Field 'name' is required." Fixed by setting such keys' name fields to an empty string. This prevents the error from being raised and the authorized_keys files round-trip successfully. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * simplify and fix portage providerBenedikt Böhm2009-11-191-27/+23
| | | | | | | | | | | | | | * use easily parsable format string (fixes #1872) * only query stable packages, anything else cannot be installed anyway * fix withenv usage in class method self.instances * code cleanup & consistency
| * Possible workaround for #2824 (MRI GC bug)Markus Roberts2009-11-193-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a moderately ugly workaround for the MRI garbage collection bug (see the ticket for details). I explored several other potential solutions (notably, monkey patching the routines that trigger the bug) but none of them were satisfactory. Monkey patching sub, gsub, sub!, gsub!, etc., for example, either changes the scoping of $~, $1, etc. in a way that could potentially subtly change the meaning of programs or (if you are clever) faithfully reproduces the behaviour of MRI--including the memory leak. I decided to go with the standardized and somewhat obnoxious never- used optional argument as it was easy to automatically insert and should be even easier to automatically find and remove if a better fix is developed. It also should be obtrusive enough to escape accidental removal in refactoring.
| * Fixing #2767 invoke-rc.d warningsJesse Wolfe2009-11-121-1/+1
| | | | | | | | | | | | | | | | Errors written to STDERR by Debian's invoke-rc.d are spurious, since we're only using it to query whether a service can be started. I'm adding the --quiet flag to suppress those messages. Signed-off-by: Jesse Wolfe <jes5199@gmail.com>
| * Ticket #2665: Regexp exception on ++ in package namesMarkus Roberts2009-10-254-4/+4
| | | | | | | | | | | | | | | | | | | | | | This affects several providers: dpkg, rug, up2date, urpmi Fixed by escaping the package names with Regexp.escape Patch by Jesse Wolf Signed-off-by: Markus Roberts <Markus@reality.com>
| * Fixed #2737 - The zone provider needs to get acquainted with OpenSolarisMartin Englund2009-10-241-3/+12
| |
* | type augeas: add 'incl' and 'lens' parametersDavid Lutterkort2009-10-241-0/+7
|/ | | | | | | | | | | | | | These parameters allow loading a file anywhere on the filesystem; using them also greatly speeds up processing the resource. * lib/puppet/type/augeas.rb: add 'incl' and 'lens' parameters; change default for 'context' when 'incl' is given. * lib/puppet/provider/augeas/augeas.rb: when 'lens' and 'incl' are given, only load that file * spec/unit/type/augeas.rb: check that constraints on new parameters are enforced This fixes ticket #2694
* Ticket #2685 (Type error in ssh_authorized_keys)Markus Roberts2009-10-231-12/+6
| | | | | | | | | | | In post processing a Symbol was being passed to StringScanner. StringScanner was not happy with this. The error message lost backtrace information and the test coverage was both inadequate and broken (see #2745). To be fully effective, this patch needs/assumes the patch for Signed-off-by: Markus Roberts <Markus@reality.com>
* Fix for #2736, target doesn't work for ssh_authorized_keysMarkus Roberts2009-10-211-35/+1
| | | | | | | | There were a number of problems here (duplicated code, meaningless tests, etc.) but the core was that the last definition of target ignored the provided value if there was also a user specified. Signed-off-by: Markus Roberts <Markus@reality.com>
* This updates the portage provider in three ways:Benedikt Böhm2009-10-051-5/+15
| | | | | | * update-eix is deprecated and will be removed from stable soon * update format string form eix-0.18 * fix format string for >=eix-0.18
* Fixes #2688. Macauthorization provider now handles booleans internally ↵Nigel Kersten2009-09-301-12/+12
| | | | correctly.
* Fix #2642 - Runit provider reworkBrice Figureau2009-09-221-14/+4
| | | | | | | | | | | The runit provider was left broken after some work on daemontools on which runit is based, and #2640 didn't override the restart command, so daemontools once was called. This patch aims to fix this provider and bring it on par with daemontools. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* Fixes #2648. Spurious macauthorization parameter changesNigel Kersten2009-09-191-4/+4
|
* Fix #2640 - Daemontools and Runit were not creating the enable symlinkBrice Figureau2009-09-162-13/+10
| | | | | | | | Due to an incorrect tests, those providers weren't enabling themselves when starting, thus failing to create the symlink necessary for them to run. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* This further normalizes the handling of init-style services (includingMarkus Roberts2009-09-053-58/+36
| | | | | | | | | the redhat "service" wrapper script). Removes special case handling of non-zero exit code in redhat (base already did this) and centralizes scattered @resource[:has_____] checks. Tests that proper versions of each are called and one level of fallbacks. Signed-off-by: Markus Roberts <Markus@reality.com>
* Combined fix for #2525, #2552 -- RedHat service issuesMarkus Roberts2009-09-051-1/+9
| | | | | | | | | This patch normalizes the structure of the RH service routines which should clear up any lingering issues; xxxcmd routines always return an appropriate array, while the coresponding routines (status/restart/ etc.) either call super or take the needed actions. Signed-off-by: Markus Roberts <markus@phage.local>
* Fixed #2589 - Renamed zfs delete to destroy and added testsJames Turnbull2009-09-051-1/+1
|
* Fixes #2581. Use new 10.6 global launchd overrides file for service ↵Nigel Kersten2009-09-031-10/+82
| | | | status/enabled
* Explicitly loading all facts in the directory service providerLuke Kanies2009-08-241-0/+3
| | | | | | | | We otherwise have load-order issues, where this provider tries to use the facts but they aren't currently autoloaded by default in Facter. Signed-off-by: Luke Kanies <luke@madstop.com>
* Fixes #2513. debian service provider now uses invoke-rc.d to determine ↵Nigel Kersten2009-08-181-11/+19
| | | | enabled? status
* Fixed #2530 - Fixed status setting in the SMF providerJames Turnbull2009-08-151-1/+1
|