summaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | | | | | | (#6337) Fix Ruby warning on 1.8.6 about "future compatibility"Daniel Pittman2011-02-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ruby 1.8.6 (but not later versions) warn about requiring parenthesis on some function calls; having one of those in our network rights checking means that we emit ... quite a few of these, and annoy anything that tracks our logs. By using the more standard form of raise we can avoid the warning entirely, and keep consistent code style across the file. Reviewed-By: Paul Berry <paul@puppetlabs.com>
| * | | | | | | | | | (#5150) Make fact REST terminus configurable to connect to inventory serviceMatt Robinson2011-02-172-2/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Puppet masters can now set the inventory_server and inventory_port option to point to another puppet master that will function as the central inventory service. When agents connect to the puppet master, this will send fact data from the puppet master over REST to the inventory service. The puppet master itself will still store the client fact data in the local yaml dir by setting the cache class to yaml. Getting puppet masters to talk to each other using certs is difficult. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| * | | | | | | | | | (#5166) Inventory service is now searchable by timestamp.Paul Berry2011-02-171-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is now possible to specify queries in the form “meta.timestamp.xx” where xx is eq,ne,gt,lt,ge,le when searching the inventory service.
| * | | | | | | | | | Maint: backport timestamp accessor for facts from 2.7 branchPaul Berry2011-02-171-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| * | | | | | | | | | Refactor Puppet::Node::Inventory::Yaml in preparation for adding freshnessPaul Berry2011-02-171-17/+29
| | | | | | | | | | |
| * | | | | | | | | | (#5132) Provide a query REST interface for inventoryPaul Berry2011-02-177-3/+59
| | |_|_|_|/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This REST interface returns a list of nodes that match a fact query. Fact queries can use (in)equality testing as a string comparison, and >, <, >=, <= numerical comparisons. Multiple tests can be done as AND comparisons, not OR. The fact queries need to be prefixed by facts, and the comparisons other than equality are specified with a .comparison_type after the fact name. This will be better explained in the REST documentation on the website. Searches that don't match anything now return empty array instead of a 404 error. Conflicts: spec/spec_helper.rb
| * | | | | | | | | (#5935) Allow functions to accept negated valuesNick Lewis2011-02-172-962/+980
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function(-1) was failing because the grammar wasn't allowing negated values in function calls. This fix makes the negation of any value which was previously legal as a function argument also now legal as a function argument. Paired-With: Max Martin Paired-With: Markus Roberts
| * | | | | | | | | (#6346) Move the trap calls onto Signal so they're easier to stubMatt Robinson2011-02-168-10/+10
| | |/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Once you stub signal traps in tests, you can hit ctrl+c in the middle of a spec run and it will stop the run instead of puppet catching the SIGINT. I had trouble easily tracking down all the places to stub traps when the trap was being called as a private method on applications and daemons, but calling trap on Signal is equivalent since Kernel calls Signal.trap and Object mixes in Kernel to provide trap as a private method on all objects. A bigger solution would be to refactor everywhere we call trap into a method that's called consistently since right now we sprinkle SIGINT and SIGTERM trap handling over applications and daemons in inconsistent ways, returning different error codes and using different messages. I've captured this info in ticket #6345. Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
| * | | | | | | | Merge branch '2.6.x' into 2.6.nextJacob Helwig2011-02-142-6/+5
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 2.6.x: Updated CHANGELOG for 2.6.5rc4 (#3646) Fix the documentation fix for `puppet apply --apply`
| | * | | | | | | (#3646) Fix the documentation fix for `puppet apply --apply`Jacob Helwig2011-02-142-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --apply is actually off of `puppet apply`, not off of `puppet agent` (nor `puppet master`), so move the documentation accordingly. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| * | | | | | | | Merge branch '2.6.x' into 2.6.nextJacob Helwig2011-02-142-8/+9
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 2.6.x: Updated CHANGELOG for 2.6.5rc3 Updated fix for #3646 - apply / compile documentation
| | * | | | | | | Updated fix for #3646 - apply / compile documentationJames Turnbull2011-02-142-8/+9
| | | | | | | | |
| * | | | | | | | (Fixes #6269) merge changes from masterzen that resolve the issue.Daniel Pittman2011-02-122-393/+401
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | parser.rb manually rebuilt to resolve global grammer chances.
| | * | | | | | | | Fix #6269 - Hashes only work with two levels of accessBrice Figureau2011-02-122-800/+793
| | | |/ / / / / / | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following manifest was failing: $hash = { 'a' => { 'b' => { 'c' => 'it works' } } } $out = $hash['a']['b']['c'] because of a typo in the grammar. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| * | | | | | | | (#5516) Rebuild parser.rb after merge.Daniel Pittman2011-02-121-1541/+1630
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The automatically generated parser.rb needed to be rebuilt to make the syntax changes functional; this commits only that rebuild.
| * | | | | | | | Merge branch 'masterzen/tickets/2.6.x/5516' into ↵Daniel Pittman2011-02-122-426/+416
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bug/2.6.next/5516-hashes-can't-be-used-in-selectors
| | * | | | | | | | Fix #5516 - Hashes can't be used in selectorsBrice Figureau2011-02-122-426/+416
| | |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following manifest was producing a parse error: $int = { 'eth0' => 'bla' } $foo = $int['eth0'] ? { 'bla' => 'foo', default => 'bleh' } because selectors didn't support hash access. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| * | | | | | | | Merge branch 'masterzen/tickets/2.6/5720' into ↵Daniel Pittman2011-02-124-8/+13
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bug/2.6.next/5720-puppetdoc-fails-on-parameterized-class
| | * | | | | | | | Fix #5720 - puppetdoc misses some class commentsBrice Figureau2011-02-112-4/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It appears that the fix for #5252 wasn't complete, and class, nodes and definition were still using the current lexer line number instead of the line number of the class/define/node token. This combined with some missing comments stack pushing/pop on parenthesis prevented puppetdoc to correctly get the documentation of some class (including parametrized ones). Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| | * | | | | | | | Fix #6281 - Make sure puppetdoc analyzes all filesBrice Figureau2011-02-111-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It can happen that when parsing a file puppet parses other manifests if they get imported (this is at least true for site.pp, even in ignoreimport=true). Thus those files are now "watched". But puppetdoc needs to analyze all files, and since 99c101 we are now checking if the file was already parsed to not reparse it again. If that was the case, though, we weren't analyzing the produced code. Thus it was possible to not produce documentation for the site.pp content. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| | * | | | | | | | Fix #6280 - puppetdoc crashing on string interpolationBrice Figureau2011-02-112-3/+3
| | |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following manifest was crashing puppetdoc: class test { include "test::$operatingsystem" } Because the quoted string is "rendered" as a concat AST, which in turn ended being an array when entering RDoc. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| * | | | | | | | (#6270) Fix formatting in split function's doc stringnfagerlund2011-02-091-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Repaired a 2-indent/4-indent issue that kept a code block from being recognized * Wrapped literal strings in backticks to format as code and protect from Markdown * Added note about backslashes for escaping metacharacters.
| * | | | | | | | (#6270) Fix formatting in regsubst function's doc stringnfagerlund2011-02-091-14/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fixed ULs being interpreted as code blocks * Changed an example for variety. * Turned set of paragraphs inside a LI into a nested list.
| * | | | | | | | (6130) Change header level on metaparameter referencenfagerlund2011-02-081-1/+1
| | |/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | Individual metaparameters under the main H2 on the page should be H3s, not H4s.
| * | | | | | | Merge remote branch 'dan/ticket/2.6.4/5977' into 2.6.nextJesse Wolfe2011-02-081-2/+6
| |\ \ \ \ \ \ \
| | * | | | | | | (5977) Puppet::Applications can be loaded from multiple paths.Dan Bode2011-01-141-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - previously, Puppet would search $LOAD_PATH and just load applications in the first $LOAD_PATH to have the directory puppet/application. Now multiple paths can contain applications.
| * | | | | | | | (#6257) Speed up PUT and POST requests under rackJesse Wolfe2011-02-081-3/+1
| | |/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch significantly speeds up reading the body of HTTP requests from Rack. Reviewed-by: Markus Roberts <markus@puppetlabs.com>
* | | | | | | | (#6407) Fix spec test hang with Mocha >= 0.9.11 in zlib testingDaniel Pittman2011-03-031-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We had a combination of bad logic, and bad testing, and a nasty behaviour of Mocha <= 0.9.10 that would result in a false pass for one of our tests. This not only falsely passed, but hid an infinite loop retrying decompression on an invalid data stream; it could be triggered by anything that sent an HTTP request with an invalid compressed body, resulting in a livelock. Paired-with: Jesse Wolfe <jesse@puppetlabs.com> Signed-off-by: Daniel Pittman <daniel@puppetlabs.com>
* | | | | | | | (#6551) remove deprecated 'env' parameter to the 'exec' typeDaniel Pittman2011-03-031-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We deprecated this back in 0.24, so we can eliminate it in the next release. We ran through our deprecation period full of constant complaints to the users. Now we just fail.
* | | | | | | | Merge branch 'ticket/next/5496' into nextNick Lewis2011-03-011-5/+7
|\ \ \ \ \ \ \ \
| * | | | | | | | (#5496) zpool provider supports new 'zpool status' formatDevon Peters2011-03-011-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "Solaris 10 9/10 release (Update 9)" update changed the output from the "zpool status" command, which breaks the zpool provider. The format basically changed from "vdev" to "vdev-n" (ex: "mirror" to "mirror-0"), which the current provider doesn't recognize. This fix changes the way vdev's are checked by the zpool provider, to support either format. Reviewed-By: Nick Lewis
* | | | | | | | | Revert #5691 "Merge remote branch 'brice/feature/process-instrumentation' ↵Jesse Wolfe2011-03-016-177/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into next" This reverts commit 448a439f5abc3d51accececb678e9c5f547f7615, reversing changes made to 06939c51a3f675137b53fac8a521132a4c9cfcbe. As per discussion in http://projects.puppetlabs.com/issues/5691#note-5
* | | | | | | | | Merge remote branch 'brice/feature/process-instrumentation' into nextJesse Wolfe2011-02-256-10/+177
|\ \ \ \ \ \ \ \ \
| * | | | | | | | | Some high-level process name probesBrice Figureau2010-12-184-10/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Here is an attempt to cover with process name probes some of the longest parts of a puppet agent or master. Currently: * node compilation * individual resource evaluation * some configurer parts * individual network requests Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
| * | | | | | | | | Process name instrumentation infrastructureBrice Figureau2010-12-182-0/+141
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is special feature that changes the process name of the running puppet entity to display its current activity. It is disabled by default, and can be enabled by sending the QUIT signal to the process in question (or calling enable through the code). This system can work only if some "probes" are integrated in the core puppet codebase. Since tools to visualize process names have a large refresh time (ie more than 1s) it only makes sense to track long activities (like compilation, transaction or file serving). Those probes are the subject of a subsequent patch. This system tracks every thread activity and form a strings which will be used as the process name. Due to the way it is implemented it is possible that it doesn't work on all platforms (I tested successfully on osx and linux). On some systems the space available is dependent on the original size of the full command. That's why if this string is longer than a 50 characters, the string is scrolled (like stock market tickers). Note: This is not intended to be a generic instrumentation system. Also, being block based means that it can reduce performance if the instrumentation probes are used in tight inner loops. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* | | | | | | | | | (#1204) Fix --param flag in puppet resource manpagenfagerlund2011-02-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ronn doesn't like <param> for some reason.
* | | | | | | | | | (#1204) Edit content and formatting of puppet resource helpnfagerlund2011-02-171-45/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Clarified how to modify the system state with puppet resource, and reformatted the markdown for compatibility with ronn.
* | | | | | | | | | (#1204) Edit content and formatting of puppet queue helpnfagerlund2011-02-171-17/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Puppet queue had inadequate help, so I added to it while reformatting for ronn.
* | | | | | | | | | (#1204) Fix --compile and --apply optionsnfagerlund2011-02-172-10/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Forward-porting a fix from 2.6.x to the new help text locations.
* | | | | | | | | | (#1204) Reformat help text for puppet masternfagerlund2011-02-171-28/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Markdown changes for compatibility with ronn.
* | | | | | | | | | (#1204) Reformat help text for puppet kick and inspectnfagerlund2011-02-172-51/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Markdown changes for compatibility with ronn.
* | | | | | | | | | (#1204) Reformat help text for puppet filebucketnfagerlund2011-02-171-29/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Markdown changes for compatibility with ronn.
* | | | | | | | | | (#1204) Fix garbled help for puppet filebucketnfagerlund2011-02-171-21/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The actual text was somewhat disarrayed. No ronn fixes in this patch.
* | | | | | | | | | (#1204) Edit content of puppet describe helpnfagerlund2011-02-171-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's a simple tool, it doesn't need both synopsis and description. Especially when they're identical.
* | | | | | | | | | (#1204) Reformat help text for puppet cert and describenfagerlund2011-02-172-73/+90
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Markdown changes for compatibility with Ronn.
* | | | | | | | | | (#1204) Edit content and formatting of puppet apply helpnfagerlund2011-02-171-33/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The puppet apply help was somewhat lacking, so I edited the content while making its formatting ronn-compatible.
* | | | | | | | | | (#1204) Reformat help text for puppet doc and puppet agent.nfagerlund2011-02-172-149/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Markdown changes for compatibility with Ronn, in the interest of better manpages.
* | | | | | | | | | Merge branch '2.6.x' into nextNick Lewis2011-02-032-1/+2
|\ \ \ \ \ \ \ \ \ \ | | |_|/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: lib/puppet/util/zaml.rb
| * | | | | | | | | Updated CHANGELOG and version for 2.6.5rc1Nick Lewis2011-02-031-1/+1
| | | | | | | | | |
| * | | | | | | | | Merge branch 'bug/2.6.next/5755-gc-issue' into 2.6.nextPaul Berry2011-02-031-0/+2
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * bug/2.6.next/5755-gc-issue: Fix for #5755 -- making zaml serialization robust over projected objects