salt-ttp

Compatibility

Salt Version Linux Windows macOS
master 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9
v3002.7 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9
v3003.3 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9
v3004 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9 3.5 3.6 3.7 3.8 3.9

Description

SALTSTACK TTP

Repository to store TTP based SALTSTACK modules:

  • salt-ttp execution module

  • salt-ttp runner module

TTP modules pull request

Motivation

TTP is a library for parsing semi structured text using templates.

TTP execution and runner modules allow to run commands against minions to obtain text output, parse it using TTP templates and return structured data.

Sample use cases that TTP can help to address:

  • reporting across several minions by parsing text output and returning text tables

  • transforming text data in structured format for storing in mine

  • time series data can be produced using TTP templates and pushed to databases using returners

  • compliance testing by parsing text into structured data with further processing and analysis to detect deviations

  • Given that text data can be transformed into structured data of arbitrary hierarchy, this modules can significantly expand functionality in the area of minions state analysis and processing.

Installation

To use TTP execution module make sure to install salt-ttp on minion, to use TTP runner module make sure to install salt-ttp on master.

From PyPi distribution:

pip install salt-ttp

From GitHub repository:

python -m pip install git+https://github.com/dmulyalin/salt-ttp

To use templates from TTP templates collection, need to install them as well:

pip install ttp_templates

How to use

Run commands to explore doc strings for further usage:

salt minion-id sys.doc ttp