is there a way to format sensu emails to only receive certain parts?
Right now im getting this whole thing:
{“id”:“f5d4897c-1262-4488-b9bd-be0d95ec12fa”,“client”:{“name”:“compute-20.moc.ne.edu”,“address”:“129.10.3.20”,“bind”:“127.0.0.1”,“port”:“3030”,“subscriptions”:[“moc-sensu”],“safe_mode”:false,“keepalive”:{},“version”:“0.20.3”,“timestamp”:1457125387},“check”:{“handlers”:[“default”,“influxdb-cpu”,“idle-email”],“type”:“metric”,“command”:"/etc/sensu/plugins/cpu-pcnt-usage-metrics.rb -t 20",“subscribers”:[“moc-sensu”],“interval”:300,“handler”:“debug”,“name”:“cpu_pcnt_metrics”,“issued”:1457125402,“executed”:1457125403,“duration”:1.049,“output”:“critical\n”,“status”:2,“history”:[“0”,“0”,“0”,“2”,“2”,“2”,“2”,“2”,“0”,“2”,“2”,“2”,“2”,“2”,“2”,“2”,“2”,“2”,“2”,“2”,“2”],“total_state_change”:4},“occurrences”:12,“action”:“create”,“timestamp”:1457125403}
When all I really want is the client name, address and the output (critical)
Anyone know how to do this?
Thanks!