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
Christ Follower, Husband, Father, Technologist. I love community and I especially love THIS community. My background is networking, but I've dabbled in all the F5 iStuff, I'm a recovering Perl guy, and am very much a python enthusiast. Learning alongside all of you in this accelerating industry toward modern apps and architectures.JRahm
Admin
Nov 30, 2017The partitionAccess field is a list of attributes on the primary user object, but not a subcollection. A true subcollection, like pool members, is addressed like this:
>>pool = b.tm.pools.pool.load(name='testpool')
>>members = pool.members_s.get_collection()
>>for member in members:
... print member.name
10.10.10.100:80
192.168.103.20:80
To get to your attributes and change them, you just need to pull the dictionary indexed at list item 0:
>>> u = b.tm.auth.users.user.load(name='jason')
>>> u.partitionAccess[0]['role']
u'irule-manager'
>>> u.partitionAccess[0]['role'] = 'guest'
>>> u.update()