Skip to content

Added BIGIP license installation#1485

Merged
jasonrahm merged 1 commit intoF5Networks:developmentfrom
drenout:development
Jul 25, 2018
Merged

Added BIGIP license installation#1485
jasonrahm merged 1 commit intoF5Networks:developmentfrom
drenout:development

Conversation

@drenout
Copy link
Copy Markdown

@drenout drenout commented Jul 24, 2018

Added license installation command similar to the revoking the license:

mgnt = ManagementRoot(bigip_mgnt, user, passwd)
mgnt.tm.sys.license.exec_cmd('install', registrationKey=regkey)

Issues:
Fixes #1483

Problem: It was not possible to install BIGIP license via f5-sdk

Analysis:
Added install command to the _meta_data['allowed_commands'] of the License object

Tests:

  • Added unit test to make sure that install command is allowed and executed with the appropriate arguments
  • Performed the functional tests with the hardware BIGIP:
    • With the correct license key, object returned by the mgnt.tm.sys.license.exec_cmd('install', registrationKey=regkey) command has 'commandResult': 'New license installed\n' attribute and BIGIP has installed regkey license
    • With the incorrect license key, object returned by the mgnt.tm.sys.license.exec_cmd('install', registrationKey=incorrect_regkey) command has 'commandResult': 'License server has returned an exception.\n Fault code: XXXX\n Fault text: Error XXXX, Production Key cannot be used in the Internal Development/PD environment - Key : XXXX\n' attribute and previous license key remains on the BIGIP

@jasonrahm
Copy link
Copy Markdown

@drenout can you change your two append lines to this line instead:

self._meta_data['allowed_commands'].extend(['revoke', 'install'])

@drenout
Copy link
Copy Markdown
Author

drenout commented Jul 24, 2018

@jasonrahm done. Thank you for the comment.

@jasonrahm jasonrahm merged commit 961348c into F5Networks:development Jul 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants