Mercurial > repos > fubar > brokenandnotdeletablebyowneroradmin
diff rgToolFactory.py @ 25:8cc3f3c0e539 default tip
Now uses admin_users to check that the user is authorized to run this tool
Docs adjusted.
author | Ross Lazarus <ross.lazarus@gmail.com> |
---|---|
date | Wed, 06 Jun 2012 14:16:25 +1000 |
parents | 0ee2b06ea304 |
children |
line wrap: on
line diff
--- a/rgToolFactory.py Wed Jun 06 12:05:25 2012 +1000 +++ b/rgToolFactory.py Wed Jun 06 14:16:25 2012 +1000 @@ -38,10 +38,7 @@ # Totally insecure. So, trusted users only # # preferred model is a developer using their throw away workstation instance - ie a private site. -# no real risk. -# a list in the xml source file is searched for users permitted to run this tool. -# PUT some IDs in the list in the XML before you restart Galaxy to load this new tool please -# otherwise, the tool won't run for anybody. +# no real risk. The universe_wsgi.ini admin_users string is checked - only admin users are permitted to run this tool. # # @@ -407,7 +404,7 @@ a('--tool_desc',default=None) a('--new_tool',default=None) opts, args = op.parse_args() - assert not opts.bad_user,'%s is NOT authorized to use this tool. Please ask your friendly admin to add their ID to %s.xml' % (opts.bad_user,os.path.splitext(self.myname)[0]) + assert not opts.bad_user,'%s is NOT authorized to use this tool. Please ask your friendly admin to add their ID to admin_users in universe_wsgi.ini' % (opts.bad_user) assert opts.tool_name,'## Tool Factory expects a tool name - eg --tool_name=DESeq' assert opts.interpreter,'## Tool Factory wrapper expects an interpreter - eg --interpreter=Rscript' assert os.path.isfile(opts.script_path),'## Tool Factory wrapper expects a script path - eg --script_path=foo.R'