3
# Source debconf library.
4
. /usr/share/debconf/confmodule
6
# Source the dbconfig library only if dbconfig-common in installed
7
if [ -f /usr/share/dbconfig-common/dpkg/config.mysql ]; then
8
. /usr/share/dbconfig-common/dpkg/config.mysql
12
# Establish the preliminaries.
16
# Is the password known
17
db_fget bugzilla3/bugzilla_admin_pwd seen
18
if [ "$RET" = "true" ]; then
19
db_get bugzilla3/bugzilla_admin_pwd || true
20
db_set bugzilla3/pwd_check "$RET"
22
db_set bugzilla3/pwd_check ""
25
# prompt the user for values
27
db_input high bugzilla3/bugzilla_admin_name || true
28
db_input high bugzilla3/bugzilla_admin_real_name || true
29
if db_input high bugzilla3/bugzilla_admin_pwd || [ ! "$?" = "30" ] ; then
30
db_input high bugzilla3/pwd_check || true
36
for FIELD in bugzilla_admin_name bugzilla_admin_real_name; do
37
db_get bugzilla3/$FIELD || true
38
if [ "$RET" = "" ]; then
39
#none of theres field should be empty
40
db_reset bugzilla3/$FIELD
44
db_get bugzilla3/bugzilla_admin_pwd || true
46
db_get bugzilla3/pwd_check || true
47
if [ "$RET" != "$PWD" ]; then
48
db_reset bugzilla3/bugzilla_admin_pwd
49
db_reset bugzilla3/pwd_check
50
db_reset bugzilla3/pwd_check