Ansible playbook to execute arbitrary commands on any Check Point Gaia host or VSX Virtual System.
GitHub: https://github.com/duanetoler/run_clish_command/
Usage: run_clish_command.sh [ -l <list of targets> ] [ -i inventory ] [ -h ] [-c <command>]
i Specify an inventory (optional; default to inventory.yml in local dir)
l List of targets, comma-separated; defaults to all hosts
s Save output to clish_output/ directory
O Do NOT show output on console (default is to show output); recommended to use with -s
c CLISH command to run; default: "show hostname"
h This help
By default, the playbook will show output of the CLISH commands and not save anything locally. Any valid Ansible target list can be provided with -l, including groups, hosts, and comma-separated lists of targets.
A default command "show hostname" is used if -c is not provided. Any valid CLISH command can be used, not just "show" commands.
Examples:
./run_clish_command.sh -i /etc/ansible/inventory.yml -c 'show route static'
./run_clish_command.sh -i /etc/ansible/inventory.yml -l VS01,VS09,daltx_cluster02 -c 'show bgp peers'
./run_clish_command.sh -i /etc/ansible/inventory.yml -l mds,mgmt02,office-fw -c 'set snmp contact "Support Team"'
./run_clish_command.sh -i /etc/ansible/inventory.yml -c 'show configuration' -s -O
README.md contains important information for how to configure your inventory and Gaia API authentication.
Operations.md documents the playbook operation and design.
In case of any issue or a bug (🐛 😱), please open GitHub issue or send me an email . For best results, please use a gist to send any output examples of your issue (clearing any sensitive bits, of course).
License: GNU General Public License v3.0 or later.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.