SalesAmerSP / f5_data_group_manager

Python-based web application to manage BIG-IP data groups using iControl REST

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

F5 Data Groups Management

Overview

F5 Data Groups Management is a web application built with Flask that allows you to manage data groups on F5 BIG-IP devices. The application provides functionalities to create, update, delete, and import/export data groups.

Features

  • Create, update, and delete data groups
  • Import data groups from files (CSV, JSON) and URLs
  • Export data groups to CSV and JSON files
  • Manage BIG-IP devices and deploy data groups to them
  • Browse and manage data groups on BIG-IP devices

Prerequisites

  • Python 3.6 or higher
  • virtualenv (optional but recommended)

Installation

Clone the Repository

git clone https://github.com/yourusername/my_flask_app.git
cd my_flask_app

Create a Virtual Environment

It's recommended to create a virtual environment to manage your dependencies.

python3 -m venv venv

Activate the Virtual Environment

On macOS and Linux:

source venv/bin/activate

On Windows:

venv\Scripts\activate

Install Dependencies

pip install -r requirements.txt

Create a secret key

A secret key is used to salt the device passwords in the devices.json file that is created when BIG-IPs are configured in the app.

Run the following command in the root directory of the project to create a unique secret key. If this file is modified or deleted, you will need to remove all BIG-IPs from the application and re-add them after regenerating the file.

python3 create_secret_key.py

Running the Application

python f5-dgm.py

Usage

Accessing the Application

Once the application is running, you can access it by navigating to https://127.0.0.1:8443 in your web browser.

Managing Data Groups

  • Create Data Group: Click on the "Create New Data Group" button, fill in the details, and submit.
  • Update Data Group: Click on a data group name from the list, modify the details, and apply changes.
  • Delete Data Group: Click on the "Delete" button next to a data group.

Import/Export Data Groups

  • Import from File: Use the "Import from File" button to upload a CSV or JSON file containing data groups.
  • Import from URL: Use the "Import from URL" button to specify a URL pointing to a CSV or JSON file.
  • Import from BIG-IP: Use the "Import from BIG-IP" button to fetch data groups from configured BIG-IP devices.
  • Export to CSV/JSON: Click on the "Export CSV" or "Export JSON" buttons next to a data group.

Managing BIG-IP Devices

  • Add Device: Navigate to the BIG-IP management page, click "Add Device", fill in the details, and submit.
  • Update Device Credentials: Click on a device name, modify the credentials, and apply changes.
  • Remove Device: Click on the "Remove" button next to a device.

Deploying and Removing Data Groups on BIG-IPs

  • Deploy Data Groups: Use the "Deploy to BIG-IP" button, select devices and data groups, and deploy.
  • Remove Data Groups: Use the "Remove from BIG-IP" button, select devices and data groups, and remove.

Security

The application enforces HTTPS using Flask-Talisman. Ensure that your secret keys and sensitive configurations are properly secured.

Contributing

Contributions are welcome! Please open an issue or submit a pull request on GitHub.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Contact

For any inquiries or support, please open a Github issue in this repository.

About

Python-based web application to manage BIG-IP data groups using iControl REST


Languages

Language:Python 54.6%Language:HTML 39.9%Language:CSS 5.5%