Browse Source

Updated edir-version.py with even more instructions to reflect same info as edir-version.sh

Michael Honkoop 5 months ago
parent
commit
214a932094
1 changed files with 3 additions and 0 deletions
  1. 3 0
      edir-version.py

+ 3 - 0
edir-version.py

@@ -5,11 +5,14 @@
 # Initial release of localcheck in python to get version information of ndsd
 # Initial release of localcheck in python to get version information of ndsd
 #
 #
 # This check should be placed in /usr/lib/check_mk_agent/local and made executable with `chmod +x edir-version.py`
 # This check should be placed in /usr/lib/check_mk_agent/local and made executable with `chmod +x edir-version.py`
+# The script assumes that you have exported the environment variables when installing eDirectory, if not it will fail/not get detected on discovery.
 
 
 import subprocess
 import subprocess
 
 
+# The process to be executed
 myexec = "ndsd"
 myexec = "ndsd"
 
 
+# Attempt to execute the process, if successful output CheckMK formatted data, if not return nothing.
 try:
 try:
     output = subprocess.check_output([myexec, "--version"])
     output = subprocess.check_output([myexec, "--version"])
     output_arr = output.split(' ')
     output_arr = output.split(' ')