F5 playbook

hello everyone,
I’d like to write a playbook which manages a bunch of F5-LTM network balancers.
As far as I can see there are some plugins for automating pools creation:
http://docs.ansible.com/bigip_pool_member_module.html

What I actually need is automating the creation of the UCS file (the F5 complete configuration backup package), its movement to an FTP server and exectute some other commands in tmsh shell, which is the native F5 shell.
In fact, F5 supports both bash-like commands and tmsh [argument 1] [argument 2]

Do I have any chance to do as I want to do by using Ansible?
I am totally new to Ansible, as I just installed it on RHEL box and I am trying to figure out if it could be the solution to my project or whether I have to get back to bash code with expect (which is bloody)

Thank you in advance

Marco

I’m going to attempt to answer this.

While I have never had to do this in Ansible, I believe what you propose is doable. Is it easy? That’s a different story. :slight_smile:

The module you found uses the Python library bigsuds to manage the F5. This makes use of the F5’s iControl SOAP API. It seems all actions for any F5 module in the extras repo uses local_action which simply has the module hitting the appropriate functions in the SOAP API.

You will most likely need to write your own module to perform the actions you are hoping to perform. That would be written in Python and can be easily dropped in. Just model your own after the existing F5 modules in core.

The way I would approach this is to first determine if the iControl SOAP API supports the functionality you desire, i.e. creation of the UCS file, commands you wish to execute via tmsh, etc. If it does, then map out what a playbook might look like and figure out what all you need in your module(s).

Not sure if that helps, but it’s my 2 cents. :slight_smile:

-matt

I have written an unreleased standalone utility which does this:

“The F5 backup tool is an agent responsible for creating and collecting “user configuration sets” (UCS) files from BIG-IP devices. A UCS file is a backup archive containing BIG-IP configuration data that can be used to fully restore a device in the event of a failure or Return Materials Authorization (RMA) replacement.”

I can see about adapting this into an Ansible module if there is demand for it.

-M