summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2005-10-28 21:28:59 +0000
committerluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2005-10-28 21:28:59 +0000
commit76176a9906f56dfbf5771471453dbe7757f426f7 (patch)
tree1998c786a4d9cf81f0d89d5bb58fefc8fb822b21 /bin
parentb6c63f6924250a14e998f4256e81c30e950fed99 (diff)
central logging is fully functional now, but it is painfully slow, so it is disabled by default
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@733 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'bin')
-rwxr-xr-xbin/puppetd20
1 files changed, 15 insertions, 5 deletions
diff --git a/bin/puppetd b/bin/puppetd
index 98d64844f..af92be6c0 100755
--- a/bin/puppetd
+++ b/bin/puppetd
@@ -12,7 +12,7 @@
# [--ssldir <cert directory>] [-l|--logdest <syslog|<file>|console>]
# [--fqdn <host name>] [-p|--port <port>] [-s|--server <server>]
# [-w|--waitforcert <seconds>] [-c|--confdir <configuration directory>]
-# [--vardir <var directory>]
+# [--vardir <var directory>] [--centrallogging]
#
# = Description
#
@@ -29,6 +29,10 @@
#
# = Options
#
+# centrallogging::
+# Send all produced logs to the central puppetmasterd system. This currently
+# results in a significant slowdown, so it is not recommended.
+#
# confdir::
# The configuration root directory, where +puppetmasterd+ defaults to looking
# for all of its configuration files. Defaults to +/etc/puppet+.
@@ -100,6 +104,7 @@ rescue LoadError
end
result = GetoptLong.new(
+ [ "--centrallogging", GetoptLong::NO_ARGUMENT ],
[ "--confdir", "-c", GetoptLong::REQUIRED_ARGUMENT ],
[ "--debug", "-d", GetoptLong::NO_ARGUMENT ],
[ "--fqdn", "-f", GetoptLong::REQUIRED_ARGUMENT ],
@@ -121,9 +126,12 @@ args = {}
waitforcert = false
+centrallogs = false
begin
result.each { |opt,arg|
case opt
+ when "--centrallogging"
+ centrallogs = true
when "--confdir"
Puppet[:puppetconf] = arg
when "--help"
@@ -187,13 +195,15 @@ if fqdn
args[:FQDN] = fqdn
end
-logdest = args[:Server]
+if centrallogs
+ logdest = args[:Server]
-if args.include?(:Port)
- logdest += ":" + args[:Port]
+ if args.include?(:Port)
+ logdest += ":" + args[:Port]
+ end
+ Puppet[:logdest] = logdest
end
-Puppet[:logdest] = logdest
client = Puppet::Client::MasterClient.new(args)