summaryrefslogtreecommitdiffstats
path: root/lib/puppet/node.rb
Commit message (Collapse)AuthorAgeFilesLines
* All non-transient parser references are goneLuke Kanies2010-02-171-19/+5
| | | | | | | | | We now use references to the ResourceTypeCollection instances through the environment, which is much cleaner. The next step is to remove the Interpreter class. Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Making sure the cert name is searched firstLuke Kanies2009-04-241-6/+14
| | | | | | | | | | | The cert name should be searched first in default circumstances, even if it disagrees with the hostname. Brice's change to the way catalogs are searched for didn't quite work when the hostname and certname didn't agree *and* the certname was fully qualified. Signed-off-by: Luke Kanies <luke@madstop.com>
* Partially fixing #1765 - node searching supports strict hostname checkingLuke Kanies2009-04-221-0/+4
| | | | | | | | With the new 'strict_hostname_checking' option enabled, the compiler will only search for the literal certificate name in its list of nodes. Signed-off-by: Luke Kanies <luke@madstop.com>
* Removing unused Node codeLuke Kanies2009-04-221-11/+0
| | | | Signed-off-by: Luke Kanies <luke@madstop.com>
* Failure to find node facts is now a failure.Luke Kanies2009-02-141-4/+8
| | | | | | | | It was previously just a warning, but the node is essentially non-functional without the facts, so it makes more sense for it to be a warning. Signed-off-by: Luke Kanies <luke@madstop.com>
* Merge branch '0.24.x' Removed the 'after' blocks that call Type.clear,Luke Kanies2008-10-171-7/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | since that method is deprecated. Conflicts: CHANGELOG bin/puppetca lib/puppet/file_serving/fileset.rb lib/puppet/network/xmlrpc/client.rb lib/puppet/type/file/selcontext.rb spec/unit/file_serving/metadata.rb spec/unit/type/file.rb
| * Fixing the Node class to no longer validate environmentsLuke Kanies2008-10-031-7/+1
| | | | | | | | | | | | since #1614 removed that validation. Signed-off-by: Luke Kanies <luke@madstop.com>
* | Merge branch '0.24.x'Luke Kanies2008-09-231-2/+4
|\| | | | | | | | | | | | | | | | | | | Conflicts: lib/puppet/metatype/container.rb lib/puppet/metatype/instances.rb lib/puppet/metatype/metaparams.rb lib/puppet/metatype/relationships.rb lib/puppet/metatype/schedules.rb
| * Fixes #1554 - Fix exception for undefined hostnameJames Turnbull2008-09-051-2/+4
| |
* | Merge branch '0.24.x'Luke Kanies2008-07-041-0/+2
|\| | | | | | | | | | | | | | | | | | | Conflicts: lib/puppet/util/settings.rb spec/integration/defaults.rb spec/unit/node/catalog.rb spec/unit/type/interface.rb spec/unit/type/ssh_authorized_key.rb
| * Adding logging when a node's facts can't be foundLuke Kanies2008-07-021-0/+2
| | | | | | | | Signed-off-by: Luke Kanies <luke@madstop.com>
* | Merge branch '0.24.x'Luke Kanies2008-06-151-82/+36
|\| | | | | | | | | | | | | | | Conflicts: CHANGELOG Finally adding release names to the changelog so we can keep the changes aligned in the right part of the log.
| * Removing the Node.find_by_name method.Luke Kanies2008-06-151-7/+0
| | | | | | | | | | We just use the regular Node.find method now, since the nodes don't need to do any magical naming.
| * Removing the now-obsolete Node.node_facts method.Luke Kanies2008-06-151-13/+0
| |
| * Converting the Node.node_names class method into an instance method.Luke Kanies2008-06-151-63/+37
| | | | | | | | | | | | | | | | This effectively removes the ability to search node termini for multiple names; only the parser will use these names. Temporarily retaining the 'find_by_any_name' method; it will be removed in a later commit.
* | Merge branch '0.24.x'Luke Kanies2008-06-141-28/+31
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also added the fixes to make the certhandler tests pass even when certs exist; I'll deal with the conflict later. Conflicts: CHANGELOG bin/puppetd lib/puppet/network/http/handler.rb lib/puppet/network/http/mongrel/rest.rb spec/integration/indirector/rest.rb spec/integration/network/server/mongrel.rb spec/integration/network/server/webrick.rb spec/unit/network/http/webrick.rb
| * Always using the cert name to store yaml files, which fixes #1178.Luke Kanies2008-05-261-28/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Master handler previously provided the support for the :node_name setting, and that functionality has now been moved into the Node class. At the same time, the names to search through have been changed somewhat: Previously, the certificate name and the hostname were both used for searching, but now, the cert name is always searched first (unless node_name == facter), but only the Facter hostname, domain, and fqdn are used otherwise. We no longer split the cert name, only the hostname/domain/fqdn. In the general case, this provides no behaviour change, because people's hostname is the same as their certname. This only results in a change in behaviour if you specify a certificate name that is a normal node name, and you want to look that node up by something other than the full name in the certificate. Signed-off-by: Luke Kanies <luke@madstop.com>
* | Merge branch '0.24.x'Luke Kanies2008-03-251-1/+1
|\| | | | | | | | | | | | | | | Conflicts: install.rb lib/puppet/defaults.rb man/man8/puppet.8
| * Moved the configuration of the Node cache to the puppetmasterdLuke Kanies2008-03-241-1/+1
| | | | | | | | | | executable, since it otherwise causes caches to be used in all cases, which we don't want (e.g., bin/puppet was using them).
* | Merge branch '0.24.x'Luke Kanies2008-03-201-1/+1
|\|
| * Caching node information in yaml (I figured caching in memory willLuke Kanies2008-03-161-1/+1
| | | | | | | | | | | | | | | | | | | | cause ever-larger memory growth), and changing the external node terminus to use the version of the facts as their version. This will usually result in the cached node information being used, instead of always hitting the external node app during file serving. Note that if the facts aren't changed by the client, then this will result in the cached node being used, but at this point, the client always updates its facts. (#1130)
* | Environments are now available as variables in manifests,Luke Kanies2008-01-201-0/+2
|/ | | | and specs can be directly executed again.
* Adding an Indirection reference, along with the workLuke Kanies2007-12-101-3/+4
| | | | necessary to support it.
* Fixing #951 -- external nodes work again, but you have toLuke Kanies2007-12-101-6/+78
| | | | set the 'node_terminus' setting to 'exec'.
* Using the Environment class to determine the default environment,Luke Kanies2007-11-201-7/+12
| | | | | rather than plenty of different places having the logic of how to determine the default environment.
* Adding a :code setting for specifying code to runLuke Kanies2007-10-051-1/+1
| | | | | | | | instead of a manifest, and removing all of the ambiguity around whether an interpreter gets its own file specified or uses the central setting. Most of the changes are around fixing existing tests to use this new system.
* Merge branch 'configurations' into indirectionLuke Kanies2007-09-221-0/+3
|\ | | | | | | | | | | | | | | | | Conflicts: lib/puppet/defaults.rb lib/puppet/indirector/facts/yaml.rb spec/unit/indirector/indirection.rb spec/unit/indirector/indirector.rb
| * The whole system now uses Configuration objects instead ofLuke Kanies2007-09-151-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ever converting the Transportable objects into a tree of components and then converting that into a graph. This is a significant step, and drastically simplifies the model of how to use a configuration. The old code might have looked something like this: file = Puppet::Type.create :path => "/whatever", ... comp = Puppet::Type.create :name => :whatever comp.push file transaction = comp.evaluate transaction.evaluate The new code looks like this: file = Puppet::Type.create :path => "/whatever", ... config = Puppet::Node::Configuration.new config.add_resource file config.apply I did not really intend to do this much refactoring, but I found I could not use a Configuration object to do work without refactoring a lot of the system. The primary problem was that the Client::Master and the Config classes determined how the transactions behaved; when I moved to using a Configuration, this distinction was lost, which meant that configurations were often needing to create other configurations, which resulted in a whole lot of infinite recursion (e.g., Config objects that create directories for Puppet use Configuration objects -- yes, I'm s/Config/Settings/g soon -- and these Configuration objects would need to create directories). Not everything is fixed, but it's very close. I am clearly over the hump, though, so I wanted to get a commit in.
* | The indirector specs now all pass. I think I needLuke Kanies2007-09-211-1/+1
| | | | | | | | to add a few more specs, though.
* | Fixing all existing spec tests so that they nowLuke Kanies2007-09-201-1/+1
|/ | | | | | pass given the redesign that Rick implemented. This was mostly a question of fixing the method names and the mocks.
* Another intermediate commit. The node and fact classes are now functional ↵Luke Kanies2007-09-121-4/+13
| | | | and are used instead of the network handlers, which have been removed. There are some failing tests as a result, but I want to get this code committed before I massage the rest of the system to make it work again.
* The Node handler is now obsolete. Node searching is handled through the ↵Luke Kanies2007-09-111-110/+5
| | | | indirector. I have not yet added the tests for the node handlers themselves, which is next.
* Doing an intermediate commit so rick can look at the work I have done so far.Luke Kanies2007-09-111-1/+120
|
* Adding a bit of testing for node names.Luke Kanies2007-08-261-1/+9
|
* Moving the node tests to rspec, and cleaning up the spec of the node, ↵Luke Kanies2007-08-261-6/+19
| | | | especially WRT the environment.
* The last commits before I actually start on the multi-environment support. ↵Luke Kanies2007-08-221-0/+40
There are still failing tests, but apparently only those that are also failing in trunk.