Getting Started with the f5-common-python SDK
Updated Jun 06, 2023
Version 2.0Was this article helpful?
Hi Jason, great work you're doing here!
I'm trying to update user parameters from the SDK. Having trouble accessing subcollection partitionAccess and user roll. Could you show an example of how to change a user roll from guest to resource admin, without resorting to exec_cmd.
u = b.tm.auth.users.user.load(name='myuser')
pp(u.raw)
'uri': u'https://mybox.com:443/mgmt/tm/auth/user/,myuser/'},
u'description': u'myuser',
u'encryptedPassword': u'!!',
u'fullPath': u'myuser',
u'generation': 1,
u'kind': u'tm:auth:user:userstate',
u'name': u'myuser',
u'partitionAccess': [{u'name': u'all-partitions',
u'nameReference': {u'link': u'https://localhost/mgmt/tm/auth/partition/all-partitions?ver=12.1.2'},
u'role': u'guest'}],
u'selfLink': u'https://localhost/mgmt/tm/auth/user/myuser?ver=12.1.2',
u'shell': u'bash'}