A Python package to get REST API Netscaler Information
Project description
Netscaler Module
Netscaler module for python 3.x
Requirements
Python 3+
Installation
$ pip install netscaler_module
Quickstart
Import the netscaler_module library to use the functions
from netscaler_module import NitroClass
....
Create a DATABASE variable and append the dicts response from nitro class.
Below an example.
DATABASE = list()
if __name__ == '__main__':
global DATABASE
ns_pool = [
{
'ip': '192.168.2.100',
'hostname': 'ns1',
'backup_name': 'ns1',
},
{
'ip': '192.168.2.101',
'hostname': 'ns2',
'backup_name': 'ns2',
}
]
password = {
'username': 'nsroot',
'password': 'XXXXXXX'
}
backup = {
'backup_folder': 'repo',
'backup_level': 'full',
}
for ns_item in ns_pool:
kwargs = ns_item | password | backup
ns = NitroClass(**kwargs)
ns.login()
if ns.master:
data = ns.get_lbvservers_binding_partitions()
DATABASE.extend(data)
ns.create_backup()
ns.download_backup()
ns.delete_backup()
ns.logout()
print(DATABASE)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
netscaler_module-1.3.tar.gz
(6.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file netscaler_module-1.3.tar.gz.
File metadata
- Download URL: netscaler_module-1.3.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
76ced91c9df5c866331d1205c6d97e459a84fb9d72e47dce0661f3650595be59
|
|
| MD5 |
eea0af0a4ce1b28946000bd986120a6a
|
|
| BLAKE2b-256 |
ae9d43218f71107133abfe8e6a9718f8ef37e58a9475e57a5ba5f699f690fd37
|
File details
Details for the file netscaler_module-1.3-py3-none-any.whl.
File metadata
- Download URL: netscaler_module-1.3-py3-none-any.whl
- Upload date:
- Size: 6.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cf8b15dc5b1e047831f62fd2de834c4b71310d15717ae838736b0ecb66cf5a7c
|
|
| MD5 |
72f7da8381594328eb8df679d152e7f6
|
|
| BLAKE2b-256 |
20042dd5eab78cdad8d3d98634456a9cdbd9032506afbdd53fe627e0a2bfd4c0
|