diff options
Diffstat (limited to 'elisp')
-rw-r--r-- | elisp/cmk.el | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/elisp/cmk.el b/elisp/cmk.el index 1a6729d..55e4435 100644 --- a/elisp/cmk.el +++ b/elisp/cmk.el @@ -97,6 +97,26 @@ Negate:\n\n") (tabulated-list-print) (display-buffer (current-buffer)))))) +(let* ((cmks (make-network-process + :name "Checkmk" + :remote "/tmp/ingridcmk.socket" + ;; :coding '(binary . binary) + :buffer "CMK" + ;; :filter (lambda (_process string) + ;; (message "%S" string)) + :sentinel (lambda (process event) + (message "Process: %s had the event '%s'" process event))))) + + (with-current-buffer (process-buffer cmks) (erase-buffer)) + (process-send-string cmks "GET services +Columns: service_description host_name service_perf_data +Filter: service_description ~ Filesystem +OutputFormat: csv +Separators: 10 124 44 124\n\n") + (accept-process-output cmks 0.1) + (with-current-buffer (process-buffer cmks) + (goto-char (point-min)) + (display-buffer (current-buffer)))) (provide 'cmk) ;;; cmk.el ends here |