git://git.onelab.eu
/
monitor.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9b360f2
)
more convenience functions to create an api interface as a user or node.
author
Stephen Soltesz
<soltesz@cs.princeton.edu>
Fri, 15 May 2009 19:48:00 +0000
(19:48 +0000)
committer
Stephen Soltesz
<soltesz@cs.princeton.edu>
Fri, 15 May 2009 19:48:00 +0000
(19:48 +0000)
monitor/wrapper/plc.py
patch
|
blob
|
history
diff --git
a/monitor/wrapper/plc.py
b/monitor/wrapper/plc.py
index
8f70c1f
..
6dc5a28
100644
(file)
--- a/
monitor/wrapper/plc.py
+++ b/
monitor/wrapper/plc.py
@@
-146,6
+146,13
@@
def getAuthAPI():
def getCachedAuthAPI():
return CachedPLC(auth.auth, auth.server)
+def getSessionAPI(session, server):
+ nodeauth = Auth(session=session)
+ return PLC(nodeauth.auth, server)
+def getUserAPI(username, password, server):
+ auth = Auth(username,password)
+ return PLC(auth.auth, server)
+
def getTechEmails(loginbase):
"""
For the given site, return all user email addresses that have the 'tech' role.