Commit 86e7734a authored by Rob Carleski's avatar Rob Carleski 🇮🇸
Browse files

Handle not being given owners in create_shared

parent 8131781f
...@@ -252,6 +252,12 @@ https://documentation.its.umich.edu/node/339/ ...@@ -252,6 +252,12 @@ https://documentation.its.umich.edu/node/339/
return return
else: else:
try: try:
if len(self.owners) == 0:
self.logger.error(
'No owners provided for new MCommunity group.',
extra={'entity': self.account}
)
exit(2)
self.logger.info( self.logger.info(
'Reserving new Mcommunity group', 'Reserving new Mcommunity group',
extra={'entity': self.account} extra={'entity': self.account}
...@@ -454,7 +460,8 @@ def main(): ...@@ -454,7 +460,8 @@ def main():
'--owners', '--owners',
'-o', '-o',
help='Uniqname(s) of shared account owner(s)', help='Uniqname(s) of shared account owner(s)',
nargs='+' nargs='+',
default={}
) )
parser.add_argument( parser.add_argument(
'--service', '--service',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment