The Problem The output of `puppet facts diff` is all smashed on one line instead of being human readable.
[root@master20198-latest-centos ~]# puppet facts diff |
{"foo.bar":{"new_value":null,"old_value":"true"},"pe_postgresql_info.data_partition_available_bytes":{"new_value":59176595456,"old_value":59176505344},"platform_tag":{"new_value":"centos-7-x86_64","old_value":"el-7-x86_64"},"puppet_inventory_metadata.packages.last_collection_time":{"new_value":"0.4702s","old_value":"0.588s"}}
|
I have to run it through another tool like python or jq to effectively read the output
[root@master20198-latest-centos ~]# puppet facts diff | python -m json.tool |
{ |
"foo.bar": { |
"new_value": null, |
"old_value": "true" |
}, |
"pe_postgresql_info.data_partition_available_bytes": { |
"new_value": 59173752832, |
"old_value": 59173863424 |
}, |
"platform_tag": { |
"new_value": "centos-7-x86_64", |
"old_value": "el-7-x86_64" |
}, |
"puppet_inventory_metadata.packages.last_collection_time": { |
"new_value": "0.463s", |
"old_value": "0.5941s" |
} |
}
|
Suggested solution We should print the output in a human readable format. |