This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var exec = require('child_process').exec; | |
var url = process.argv[2]; | |
var threshold = parseFloat(process.argv[3]); | |
var eventName; | |
var state; | |
var cmd = 'curl -o /dev/null -s -w %{time_total} ' + url; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
mailq_count=`/usr/bin/mailq | /usr/bin/tail -n1 | /usr/bin/gawk '{print $5}'` | |
mailq_count=`expr $mailq_count + 0` | |
echo "Mail count on Server is $mailq_count" | |
result="normal" | |
if [ $mailq_count -gt $1 ]; then | |
result="failure" | |
fi | |
echo $result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cd $1 | |
#For enforce local changes removal, uncomment the following line | |
#git reset --hard HEAD;git clean -fd | |
diffs=$(git diff origin |wc -l) | |
result="NORMAL" | |
echo "Verifying changes at $1, Differences between local and remote are $diffs" | |
if [ "$diffs" -gt 0 ] | |
then | |
result="FAILURE" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rem compatible from windows version 2003. Ejemplo C:,3000000 (bytes) | |
@echo off | |
set drive=%1 | |
shift | |
set threshold=%1 | |
shift | |
rem woooojojojo! todo esto solo para obtener el espacio libre . | |
for /f "usebackq delims== tokens=2" %%x in (`wmic logicaldisk where "DeviceID='%drive%'" get FreeSpace /format:value`) do set FreeSpace=%%x |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var are undefined set PASS $1 POOL $2 MEMBERS $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
MEMBERS=$3 | |
tempFile=/tmp/resultado$POOL | |
sudo rm $tempFile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#This scripts works on 11+ Version | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var are undefined set PASS $1 POOL $2 MEMBERS $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
MEMBERS=$3 | |
tempFile=/tmp/resultado$POOL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var is undefined set PASS $1 POOL $2 ipAndPort $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
ipAndPort=$3 | |
tempFile=/tmp/resultado | |
#Variable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var is undefined set PASS $1 POOL $2 ipAndPort $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
ipAndPort=$3 | |
tempFile=/tmp/resultado | |
#Variable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var is undefined set PASS $1 POOL $2 ipAndPort $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
ipAndPort=$3 | |
tempFile=/tmp/resultado | |
#Variable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
which expect > /dev/null | |
if [ "$?" -eq "1" ];then echo FAILURE | |
else | |
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ];then echo FAILURE Some var is undefined set PASS $1 POOL $2 ipAndPort $3;exit;fi | |
PASS=$1 | |
POOL=$2 | |
ipAndPort=$3 | |
tempFile=/tmp/resultado | |
#Variable |