From 45ced23005cf8f27b0a5dc71e80d73ebca598e83 Mon Sep 17 00:00:00 2001 From: Loic Baron Date: Tue, 6 Feb 2018 17:25:10 +0100 Subject: [PATCH] FIT IoT-Lab requires organization of new users: generate one from the urn --- sfa/iotlab/iotlabshell.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/sfa/iotlab/iotlabshell.py b/sfa/iotlab/iotlabshell.py index ac600970..101de84a 100644 --- a/sfa/iotlab/iotlabshell.py +++ b/sfa/iotlab/iotlabshell.py @@ -150,11 +150,17 @@ class IotLABShell(object): """ # pylint:disable=E1123 logger.warning("iotlashell add_user") + logger.warning("slice_user: %s" % slice_user) + if 'urn' in slice_user: + organization = slice_user['urn'] + else: + organization = "SFA federation" # single account creation user = {"type": "SA", "city": "To be defined", "country": "To be defined", - "motivations": "SFA federation"} + "motivations": "SFA federation", + "organization": organization} email = slice_user['email'] user['email'] = email user['sshPublicKey'] = slice_user['keys'][0] -- 2.43.0