summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael DeHaan <mdehaan@mdehaan.rdu.redhat.com>2007-09-28 12:14:41 -0400
committerMichael DeHaan <mdehaan@mdehaan.rdu.redhat.com>2007-09-28 12:14:41 -0400
commitfe69fb77f1c504b885720d2238478a2467ebac16 (patch)
tree5b05b1ecab59741289eb6f9a2f3f71d7cc82b5b9
parent4bc3029d5fceb9449ff7579a28937248d6b49d77 (diff)
downloadfunc-fe69fb77f1c504b885720d2238478a2467ebac16.tar.gz
func-fe69fb77f1c504b885720d2238478a2467ebac16.tar.xz
func-fe69fb77f1c504b885720d2238478a2467ebac16.zip
Add pretty printing for output, also remove an unused constant.
-rwxr-xr-xoverlord/client.py9
1 files changed, 3 insertions, 6 deletions
diff --git a/overlord/client.py b/overlord/client.py
index d241373..d9d5f4f 100755
--- a/overlord/client.py
+++ b/overlord/client.py
@@ -18,9 +18,10 @@
import optparse
import sys
import glob
+import pprint
+
from func.commonconfig import CMConfig
from func.config import read_config
-
import sslclient
# ===================================
@@ -28,7 +29,6 @@ import sslclient
# TO DO: some of this may want to come from config later
DEFAULT_PORT = 51234
-CERT_PATH = "/var/lib/func/certmaster/certs"
CONFIG_FILE = "/etc/func/certmaster.conf"
FUNC_USAGE = "Usage: %s [ --help ] [ --verbose ] target.example.org module method arg1 [...]"
@@ -105,9 +105,6 @@ class Client():
host = cert.replace(self.config.certroot,"")[1:-5]
all_hosts.append(host)
- # debug only:
- # print all_hosts
-
all_urls = []
for x in all_hosts:
all_urls.append("https://%s:%s" % (x, self.port))
@@ -166,7 +163,7 @@ class Client():
meth = "%s.%s" % (module, method)
retval = getattr(conn, meth)(*args[:])
if self.interactive:
- print retval
+ pprint.pprint(retval)
except Exception, e:
retval = e
if self.interactive: