Have some code. Share some code.
Showing results for 
Search instead for 
Did you mean: 
Code is community submitted, community supported, and recognized as ‘Use At Your Own Risk’.

Short Description

In this article, I will explore how to create a graphical representation of a virtual server using Python Flask, Pyvis libraries, and the IControl REST F5 API. This graphical representation will provide a visual representation of the virtual server, including the pools and pool members(servers) it is connected to, and also the URI.

(As irules can be really complex, this is mainly for irules with "if" and "switch" clauses.)


Problem solved by this Code Snippet

Having a graphical representation of how a virtual server distributes the traffic to its pools, makes it easier to understand.

How to use this Code Snippet

There are 2 main files:

  • <VIP_name>  - this is how you run it and will generate the HTML files "static" folder. - this is the app that starts the Flask web server and provides a front-end to the

There is also a Dockerfile that you can use to containerize this app.

There are 2 environment variables: Authorization_string (this is credentials(user:pass) for Basic authentication)
and IP_ADDRESS (this is the IP of the F5 device).

Code Snippet Meta Information

  1. Version: 1
  2. Coding Language: Python 3.10.9

Full Code Snippet

Here you can find the code:


Version history
Last update:
‎25-Apr-2023 05:16
Updated by: