reset: add confirmation before erasing
This commit is contained in:
parent
103184f347
commit
294507627b
|
@ -5,6 +5,12 @@ set -e
|
|||
LDIFDIR=/usr/share/slapd-supann/
|
||||
SERVICE="/usr/sbin/service slapd"
|
||||
|
||||
echo -n "WARNING! All current data will be erased. Are you sure? (type yes) "
|
||||
read ok
|
||||
if [ "x$ok" != "xyes" ]; then
|
||||
exit 3
|
||||
fi
|
||||
|
||||
${SERVICE} stop || true
|
||||
|
||||
BACKUPDIR=/var/backups/slapd-reset-`date +%Y%m%dT%H%M%S`
|
||||
|
|
Reference in New Issue