spark: add disk usage checker script
This commit is contained in:
1 parent
dd4318b4c6
commit
da4646acfe
1 file changed
+1
-3
@@ -17,6 +17,4 @@ def get_disk_usage():
|
||||
|
||||
if __name__ == "__main__":
|
||||
result = get_disk_usage()
|
||||
print(json.dumps(result, indent=2))
|
||||
# Exit with special code based on status
|
||||
exit(0 if result["status"] == "ok" else 2 if result["status"] == "warning" else 3)
|
||||
print(json.dumps(result, indent=2))
|
||||
Reference in new issue
Block a user