diff --git a/install_windows/01_install_backuppc.sh b/install_windows/01_install_backuppc.sh index edfed6d..77326ee 100755 --- a/install_windows/01_install_backuppc.sh +++ b/install_windows/01_install_backuppc.sh @@ -10,6 +10,13 @@ case $lang in *) group_name="Backup Operators" ;; esac +ip_ur1=$(wget http://checkip.dyndns.org/ -O - -o /dev/null | cut -d" " -f 6 | cut -d\< -f 1 | cut -d'.' -f1-2) + +if [[ ${ip_ur1} != "129.20" ]]; then + printf "Merci de vous connecter au réseau 'univ-rennes1' et relancer le 01_install_backuppc.exe\n" + exit 1 +fi + net user backuppc $(openssl rand -base64 8) /add # Creation compte backuppc (mot de passe aleatoire) #net localgroup "Administrateurs" backuppc /add # Ajout des droits admin a backuppc net localgroup "$group_name" backuppc /add