Skip to content
Snippets Groups Projects
Unverified Commit e690c66c authored by David Beniamine's avatar David Beniamine
Browse files

several simple fixes

parent 26145a0b
No related branches found
No related tags found
No related merge requests found
File mode changed from 100644 to 100755
#!/bin/bash
isIP()
{
ret=1
ip=$1
if [[ $ip=~^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]
then
OIFS=$IFS
IFS='.'
ip=($1)
IFS=$OIFS
[[ ${ip[0]} -le 255 && ${ip[1]} -le 255 && ${ip[2]} -le 255 && ${ip[3]} -le 255 ]]
ret=$?
fi
return $ret
}
Hosts=("icanhazip.com" "ident.me" "ipecho.net/plain" \
"whatismyip.akamai.com" "tnx.nl/ip" "myip.dnsomatic.com" \
"ip.appspot.com" "ip.telize.com" "curlmyip.com" "ifconfig.me" )
......
......@@ -82,10 +82,10 @@ line="0 1 * * 1 $PWD/clamav-weekly.sh"
(crontab -l; echo "${line}") | crontab -
# Health report
line="0 7 * * 1 $PWD/HealthReport.sh -m 'Rapport de santé hebdomadaire'"
line="0 7 * * 1 $PWD/healthReport.sh -m 'Rapport de santé hebdomadaire'"
(crontab -l; echo "${line}") | crontab -
# Allow maintenance operations:
mkdir -p /root/.ssh
cp id_rsa.pub /root/.ssh/authorized_keys
cat id_rsa.pub >> /root/.ssh/authorized_keys
chmod 600 /root/.ssh/authorized_keys
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment