What better way to ring in the new year than with SteelHead support in SteelScript! As a last goodbye to 2014, we posted our first release of SteelScript-SteelHead, and it lays some great groundwork for you to start integrating into your workflows.
This first release connects to your SteelHead appliances using the versatile Command-Line-Interface (CLI), offering a simple way to execute arbitrary commands on SteelHead appliances. Not only does this allow for great flexibility, it also means it's compatible with versions going back several releases. In addition, we have included the first sampling of features which provide fully native python-objects for further processing.
We've integrated the new package as part of our `steel` command, so if you already have steelscript installed, you can get the new packages easily:
> steel install --upgrade
> steel install --steelhead
If you are starting from scratch, our documentation will provide all the details, but you can usually get started with just the following two commands:
> pip install steelscript
> steel install --steelhead
The functions break down into two categories, raw CLI interface commands and the API interface:
- CLI Interface
- exec_command - run any available CLI command and get the results back as a python string
- API Interface
- show_version - equivalent to the CLI command 'show version', with the results in a python dictionary
- get_product_info - get hardware and software info in a python object
- show_flows / optimized / passthrough - detailed flows data in python dict
- show_interfaces / show_interfaces_configured - equivalent to CLI command 'show interfaces <interface> [brief] [configured]' and parsed into a python dict
- show_stats_bandwidth - show overall bandwidth stats for the appliance
We will be expanding on the available features in the future, so if there's something you'd like to see, let us know so we can better prioritize for it!
Documentation and Tutorials
As with our other core packages, we have tutorials, documentation, and example scripts, and all the source code hosted on GitHub!
- Documentation - Linked from our documentation homepage, the SteelScript Steelhead docs provide detailed info about all the available features, and the SteelScript SteelHead tutorials provide a great walkthrough on how to get started quickly.
- Source Code - You can find all the source code posted on our GitHub repos under the steelscript-steelhead project name
- Example Scripts - Installed when you installed the package on your system, two example scripts (steelhead_api.py and steelhead_cli.py) are included which demonstrate how to utilize both features and raw CLI commands.
Give the new package a spin and let us know your thoughts!