DevOps Stack Exchange is a question and answer site for software engineers working on automated testing, continuous delivery, service integration and monitoring, and building SDLC infrastructure. Join them; it only takes a minute:

I've a playbook that runs EOS commands against multiple devices. Currently the whole thing is done in bash, creates one massive text file log and an engineer compares each day's log to the previous one for irregularities.

I'm attempting to have one simple playbooks that runs the commands and logs to json from which it'll be easier to automate the comparison, but I've just realised only logs from one device are saved as opposed to the two I'm testing against.

2 Answers
2

Convert all Ansible output to JSON with json stdout callback and parse it with your favourite tools. The eos_command output for each device will be under different host key in the resulting json.
See this and this.