summaryrefslogtreecommitdiffstats
path: root/lib/puppet
diff options
context:
space:
mode:
authorJesse Wolfe <jes5199@gmail.com>2010-03-18 19:01:29 -0700
committertest branch <puppet-dev@googlegroups.com>2010-02-17 06:50:53 -0800
commit1603f7363728dc41f67cd189ca0dcbf074ec44b4 (patch)
tree022fa3e476f75ef536e4db4704a1bd4e813ac729 /lib/puppet
parent16658a0403135bc23ce18bcf2c72c4725ac25faf (diff)
downloadpuppet-1603f7363728dc41f67cd189ca0dcbf074ec44b4.tar.gz
puppet-1603f7363728dc41f67cd189ca0dcbf074ec44b4.tar.xz
puppet-1603f7363728dc41f67cd189ca0dcbf074ec44b4.zip
Feature #3394 REST Runner, preparation
Rename Puppet::Agent::Runner to Puppet::Run, for consistency
Diffstat (limited to 'lib/puppet')
-rw-r--r--lib/puppet/agent.rb2
-rw-r--r--lib/puppet/indirector/run/rest.rb6
-rw-r--r--lib/puppet/indirector/runner/rest.rb7
-rwxr-xr-xlib/puppet/network/handler/runner.rb4
-rw-r--r--lib/puppet/run.rb (renamed from lib/puppet/agent/runner.rb)2
5 files changed, 9 insertions, 12 deletions
diff --git a/lib/puppet/agent.rb b/lib/puppet/agent.rb
index f07305559..84bda6756 100644
--- a/lib/puppet/agent.rb
+++ b/lib/puppet/agent.rb
@@ -8,8 +8,6 @@ class Puppet::Agent
require 'puppet/agent/locker'
include Puppet::Agent::Locker
- require 'puppet/agent/runner'
-
attr_reader :client_class, :client, :splayed
# Just so we can specify that we are "the" instance.
diff --git a/lib/puppet/indirector/run/rest.rb b/lib/puppet/indirector/run/rest.rb
new file mode 100644
index 000000000..7cf6411f1
--- /dev/null
+++ b/lib/puppet/indirector/run/rest.rb
@@ -0,0 +1,6 @@
+require 'puppet/run'
+require 'puppet/indirector/rest'
+
+class Puppet::Run::Rest < Puppet::Indirector::REST
+ desc "Trigger Agent runs via REST."
+end
diff --git a/lib/puppet/indirector/runner/rest.rb b/lib/puppet/indirector/runner/rest.rb
deleted file mode 100644
index 25d3def3f..000000000
--- a/lib/puppet/indirector/runner/rest.rb
+++ /dev/null
@@ -1,7 +0,0 @@
-require 'puppet/agent'
-require 'puppet/agent/runner'
-require 'puppet/indirector/rest'
-
-class Puppet::Agent::Runner::Rest < Puppet::Indirector::REST
- desc "Trigger Agent runs via REST."
-end
diff --git a/lib/puppet/network/handler/runner.rb b/lib/puppet/network/handler/runner.rb
index 070cae114..4f8247214 100755
--- a/lib/puppet/network/handler/runner.rb
+++ b/lib/puppet/network/handler/runner.rb
@@ -1,4 +1,4 @@
-require 'puppet/agent/runner'
+require 'puppet/run'
class Puppet::Network::Handler
class MissingMasterError < RuntimeError; end # Cannot find the master client
@@ -20,7 +20,7 @@ class Puppet::Network::Handler
options[:ignoreschedules] = ignoreschedules if ignoreschedules
options[:background] = !fg
- runner = Puppet::Agent::Runner.new(options)
+ runner = Puppet::Run.new(options)
runner.run
diff --git a/lib/puppet/agent/runner.rb b/lib/puppet/run.rb
index 705b6c269..1503f5d7f 100644
--- a/lib/puppet/agent/runner.rb
+++ b/lib/puppet/run.rb
@@ -4,7 +4,7 @@ require 'puppet/indirector'
# A basic class for running the agent. Used by
# puppetrun to kick off agents remotely.
-class Puppet::Agent::Runner
+class Puppet::Run
extend Puppet::Indirector
indirects :runner, :terminus_class => :rest