iankelling.org
/
git
/
distro-setup
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fixes and alert improvements
[distro-setup]
/
mailtest-check
diff --git
a/mailtest-check
b/mailtest-check
index e28d5ae966750233f5778c20c26a7c1d58be54a6..03cf6ab7135ddb4ee8b1f33b669340e816ec967c 100755
(executable)
--- a/
mailtest-check
+++ b/
mailtest-check
@@
-29,7
+29,7
@@
getspamdpid() {
fi
}
pr() {
fi
}
pr() {
- if [[ -e /var/lib/prometheus/node-exporter ]]; then
+ if
$doprom &&
[[ -e /var/lib/prometheus/node-exporter ]]; then
cat >>/var/lib/prometheus/node-exporter/mailtest-check.prom.$$
fi
}
cat >>/var/lib/prometheus/node-exporter/mailtest-check.prom.$$
fi
}
@@
-66,7
+66,17
@@
fi
# TODO, get je to deliver the local mailbox: /m/md/INBOX
# dovecot appears to setup, i can t be sure.
# TODO, get je to deliver the local mailbox: /m/md/INBOX
# dovecot appears to setup, i can t be sure.
-
+source /a/bin/bash_unpublished/source-state
+
+doprom=false
+case $HOSTNAME in
+ $MAIL_HOST|bk|je)
+ doprom=true
+ ;;
+ *)
+ rm -f /var/lib/prometheus/node-exporter/mailtest-check.prom*
+ ;;
+esac
main() {
main() {