only allow admins to perform non-scratch builds from srpm
This commit is contained in:
parent
c4df08125d
commit
79ef5b41f2
2 changed files with 9 additions and 0 deletions
4
cli/koji
4
cli/koji
|
|
@ -598,6 +598,10 @@ def handle_build(options, session, args):
|
|||
#relative to koji.PRIO_DEFAULT
|
||||
priority = 5
|
||||
if not source.startswith('cvs://'):
|
||||
# only allow admins to perform non-scratch builds from srpm
|
||||
if not opts['scratch'] and not session.hasPerm('admin'):
|
||||
parser.error(_("builds from srpm must use --scratch"))
|
||||
assert False
|
||||
#treat source as an srpm and upload it
|
||||
print "Uploading srpm: %s" % source
|
||||
serverdir = _unique_path('cli-build')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue