Forum Discussion
Adding a user with Ruby & iControl
Hello.
I've been knocking my brains out trying to get the Ruby iControl gem to add a user to a device. The complex type on this one is throwing me for a loop. If I can get the simple code down, I can expand it, but I can't get my head around the structure of user_info_3.
Here's my simple code:
bigip = F5::IControl.new(bigip_address, bigip_user, bigip_pass, ["Management.UserManagement"]).get_interfaces
bigip["Management.UserManagement"].create_user_3([[{'name' => 'Guest', 'full_name' => 'Guest User'}], [{'is_encrypted' => false, 'password' => 'abcd'}], [{'role' => 'USER_ROLE_GUEST', 'partition' => 'Common'}], ['/bin/false']])
Any ideas?
Thanks.
rjwiii
- Update:
- George_Watkins_Historic F5 Account
Rich,
bigip['Management.UserManagement'].create_user_3([{'user' => {'name' => 'Guest', 'full_name' => 'Guest User'}, 'password' => {'is_encrypted' => 'false', 'password' => 'abcd'}, 'permissions' => [ {'role' => 'USER_ROLE_GUEST', 'partition' => 'Common'} ], 'login_shell' => '/bin/false'}])
Best regards,
Mr. Watkins,
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com