Getting Started with the f5-common-python SDK
If you have dabbled with python and iControl over the years, you might be familiar with some of my other “Getting Stared with …” articles on python libraries. I started my last, on Bigsuds, this way:...
Updated Jun 06, 2023
Version 2.0JRahm
Admin
Joined January 20, 2005
KernelPanic
Nov 30, 2017Nimbostratus
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'}