static usb ethnet addresses
[automated-distro-installer] / fai / config / class / 41-warning.sh
1 #! /bin/bash
2
3 if [ X$FAI_ACTION = Xinstall -o X$FAI_ACTION = X ]; then
4 :
5 else
6 return 0
7 fi
8 if [ X$action = Xdirinstall ]; then
9 return 0
10 fi
11
12 grep -q INSTALL $LOGDIR/FAI_CLASSES || return 0
13 [ "$flag_menu" ] || return 0
14
15 out=$(tty)
16 # save stdout and redirect stdout to tty
17 exec 4>&1 > $out
18 red=$(mktemp)
19 echo 'screen_color = (CYAN,RED,ON)' > $red
20
21 DIALOGRC=$red dialog --colors --clear --aspect 6 --title "FAI - Fully Automatic Installation" --trim \
22 --msgbox "\n\n If you continue, \n all your data on the disk \n \n|\Zr\Z1 WILL BE DESTROYED \Z0\Zn|\n\n" 0 0
23
24 # stop on any error, or if ESC was hit
25 if [ $? -ne 0 ]; then
26 task_error 999
27 fi
28
29 rm $red
30 unset red
31 exec 1>&4 # restore stdout