aboutsummaryrefslogtreecommitdiff
path: root/modules/private/monitoring/plugins/check_ftp_database
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2020-01-05 17:08:32 +0100
committerIsmaël Bouya <ismael.bouya@normalesup.org>2020-01-05 17:08:32 +0100
commite820134d38c3b7470ea5112f40a6dc967f039878 (patch)
treef05a5cefe285d060aa0ebf52829bcfcd35549f8b /modules/private/monitoring/plugins/check_ftp_database
parentb22ce4895ef1e9723a02061f7293e528cfbf9754 (diff)
downloadNix-e820134d38c3b7470ea5112f40a6dc967f039878.tar.gz
Nix-e820134d38c3b7470ea5112f40a6dc967f039878.tar.zst
Nix-e820134d38c3b7470ea5112f40a6dc967f039878.zip
Add monitoring host
Diffstat (limited to 'modules/private/monitoring/plugins/check_ftp_database')
-rwxr-xr-xmodules/private/monitoring/plugins/check_ftp_database11
1 files changed, 11 insertions, 0 deletions
diff --git a/modules/private/monitoring/plugins/check_ftp_database b/modules/private/monitoring/plugins/check_ftp_database
new file mode 100755
index 0000000..9a41424
--- /dev/null
+++ b/modules/private/monitoring/plugins/check_ftp_database
@@ -0,0 +1,11 @@
1#!/usr/bin/env bash
2
3OUT=$(echo "ls" | lftp -u test_ftp,test_ftp eldiron.immae.eu | grep it_works | wc -l)
4
5if [ "$OUT" -eq 1 ]; then
6 echo "ftp connection OK - access to ftp is working"
7 exit 0
8else
9 echo "ftp connection CRITICAL - no access to ftp"
10 exit 2
11fi