Description: Really give functionality to the RUN_DEPLOY env var
Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de>

--- a/ldap2bind
+++ b/ldap2bind
@@ -2,6 +2,11 @@
 
 [ -r /etc/default/ldap2zone ] && . /etc/default/ldap2zone
 
+# if shell is non-interactive (e.g. like when called via CRON) and RUN_DEPLOY is false, exit silently.
+if [ ! -t 1 ] && [ "$RUN_DEPLOY" = "false" ]; then
+        exit 0
+fi
+
 case "$LDAP_URI" in 
 ldap://*|ldaps://*|ldapi://*) ;;
 '')
