Reconfig hook is no longer interactive, per bug #107918.
authorRenat Lumpau <rl03@gentoo.org>
Mon, 3 Oct 2005 23:19:53 +0000 (23:19 +0000)
committerRenat Lumpau <rl03@gentoo.org>
Mon, 3 Oct 2005 23:19:53 +0000 (23:19 +0000)
Package-Manager: portage-2.0.51.22-r2

www-apps/bugzilla/ChangeLog
www-apps/bugzilla/Manifest
www-apps/bugzilla/bugzilla-2.18.4.ebuild
www-apps/bugzilla/files/2.18/postinstall-en.txt [new file with mode: 0644]
www-apps/bugzilla/files/2.18/reconfig
www-apps/bugzilla/files/2.20/postinstall-en.txt
www-apps/bugzilla/files/2.20/reconfig

index 39b985197035eebc7b10123150a06060338c8166..5a708d5078b80a6f31cefa6c917652451639339b 100644 (file)
@@ -1,6 +1,12 @@
 # ChangeLog for www-apps/bugzilla
 # Copyright 2000-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/bugzilla/ChangeLog,v 1.39 2005/10/02 13:45:23 corsair Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/bugzilla/ChangeLog,v 1.40 2005/10/03 23:19:53 rl03 Exp $
+
+  03 Oct 2005; Renat Lumpau <rl03@gentoo.org>
+  +files/2.18/postinstall-en.txt, files/2.18/reconfig,
+  files/2.20/postinstall-en.txt, files/2.20/reconfig,
+  bugzilla-2.18.4.ebuild:
+  Reconfig hook is no longer interactive, per bug #107918.
 
   02 Oct 2005; Markus Rothe <corsair@gentoo.org> bugzilla-2.18.4.ebuild:
   Stable on ppc64 (bug #107796)
index 47bb0ce53b7229f5a7cf0d45cd6352a5872eb963..5197898435793190518d5fd9154ddeee3c01b67e 100644 (file)
@@ -1,17 +1,28 @@
-MD5 969d9986ac47b14ce120f836910e22cb ChangeLog 9160
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
+MD5 0ce070168c2246bf32140185afcfc666 bugzilla-2.18.4.ebuild 1816
+MD5 78e27654d12a7a46a21fb069b1bd6de7 bugzilla-2.20.ebuild 1845
 MD5 246d31921cf90d0d24d5bad6f35e9a9b bugzilla-2.18.3.ebuild 1781
+MD5 b0177d04d838fb166bab7f17135ef7c7 ChangeLog 9398
 MD5 f61bfa064e3acdfcd826e4a38b121196 metadata.xml 161
-MD5 1b1e819198a06945e5a80d1e00c9af4d bugzilla-2.18.4.ebuild 1787
-MD5 78e27654d12a7a46a21fb069b1bd6de7 bugzilla-2.20.ebuild 1845
-MD5 4a34a6ec468afb645b29aaddedeef49a files/digest-bugzilla-2.18.4 68
 MD5 24f132ccd4b11bb49c26326fd0584f4c files/digest-bugzilla-2.20 66
 MD5 df412a960ab7899d10f4fc42b8a3cc5f files/digest-bugzilla-2.18.3 68
-MD5 42151252d49e42c9839f80c80dff9138 files/2.18/apache.htaccess 94
-MD5 0be5a588dc7fdfc9e4898a855bd32361 files/2.18/bugzilla.cron.daily 115
+MD5 4a34a6ec468afb645b29aaddedeef49a files/digest-bugzilla-2.18.4 68
 MD5 b38d67b03726b84833bd8c5f632e4020 files/2.18/bugzilla.cron.tab 54
-MD5 5d26668841a63cf6ba69e8f191a5c50a files/2.18/reconfig 3661
-MD5 42151252d49e42c9839f80c80dff9138 files/2.20/apache.htaccess 94
-MD5 0be5a588dc7fdfc9e4898a855bd32361 files/2.20/bugzilla.cron.daily 115
+MD5 06e21bd2fe59b4517ed05fb46c1bff9e files/2.18/postinstall-en.txt 148
+MD5 0be5a588dc7fdfc9e4898a855bd32361 files/2.18/bugzilla.cron.daily 115
+MD5 42151252d49e42c9839f80c80dff9138 files/2.18/apache.htaccess 94
+MD5 c1913bf27d5ee8cd7f4f88de0b88312a files/2.18/reconfig 348
 MD5 b38d67b03726b84833bd8c5f632e4020 files/2.20/bugzilla.cron.tab 54
-MD5 ec5f3f87022982a0f130cf592c0c9d83 files/2.20/postinstall-en.txt 122
-MD5 0def7ca5b4d3ddd839e4663c5d784380 files/2.20/reconfig 5004
+MD5 7b5e1b8ee2d4e49224f15287c5070b57 files/2.20/postinstall-en.txt 278
+MD5 0be5a588dc7fdfc9e4898a855bd32361 files/2.20/bugzilla.cron.daily 115
+MD5 42151252d49e42c9839f80c80dff9138 files/2.20/apache.htaccess 94
+MD5 899c42853fbf73268c49d3602eae77d2 files/2.20/reconfig 349
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.1 (GNU/Linux)
+
+iD8DBQFDQbymEzitwsaoONoRAmBaAKChtsbqD6VovBwRs0HHoD2zmi4JQQCfd3ys
+lWTXEnz9OVu5KFK5PCJfwM4=
+=I307
+-----END PGP SIGNATURE-----
index dc8f283056faa7f1c595e179d30f4c91d247d776..af703433037ca53e961b24f1bcc4e92c92027309 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/bugzilla/bugzilla-2.18.4.ebuild,v 1.3 2005/10/02 13:45:23 corsair Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/bugzilla/bugzilla-2.18.4.ebuild,v 1.4 2005/10/03 23:19:53 rl03 Exp $
 
 inherit webapp
 
@@ -59,8 +59,8 @@ src_install () {
        cd ${FILESDIR}/2.18
        cp ${FILE} ${D}/${MY_HTDOCSDIR}
 
-       # add the reconfigure hook
        webapp_hook_script ${FILESDIR}/2.18/reconfig
+       webapp_postinst_txt en ${FILESDIR}/2.18/postinstall-en.txt
 
        webapp_src_install
 }
diff --git a/www-apps/bugzilla/files/2.18/postinstall-en.txt b/www-apps/bugzilla/files/2.18/postinstall-en.txt
new file mode 100644 (file)
index 0000000..2b3391f
--- /dev/null
@@ -0,0 +1,4 @@
+Bugzilla has been installed into ${MY_INSTALLDIR}
+
+To finish the installation, please read
+http://www.bugzilla.org/docs/2.18/html/installation.html
index f62bfe278642ecdd2336562200aa3b7f57682aba..9d2c893b1711dc0575885859c37c6f46084e226d 100644 (file)
@@ -2,7 +2,7 @@
 
 FILE="bugzilla.cron.daily bugzilla.cron.tab"
 
-function die () 
+function die ()
 {
        echo
        echo "***"
@@ -12,85 +12,8 @@ function die ()
 }
 
 if [ $1 = "install" ]; then
-
        cd "${MY_INSTALLDIR}" || die "Cannot find install dir ${MY_INSTALLDIR}"
-
-       sed -e "s|/var/www/bugzilla|${MY_INSTALLDIR}|g;" -i ${FILE}
-
-       [[ -a localconfig ]] && die "The following does not work on previous installations, please run checksetup.pl in ${MY_INSTALLDIR}"
-
-       echo
-       echo "Finalizing the installation of bugzilla in ${MY_INSTALLDIR}"
-       echo
-       
-       # config setting
-       echo "Details for the bugzilla database"
-       echo "(This scripts creates the database & user)"
-       echo
-
-       echo -n "mysql bugs db host [localhost]: "; read mybugshost
-       [[ -z "${mybugshost}" ]] && mybugshost="localhost"
-
-       echo -n "mysql bugs db port [3306]: "; read mybugsport
-       [[ -z "${mybugsport}" ]] && mybugsport="3306"
-       
-       echo -n "mysql bugs db name [bugs]: "; read mybugsdb
-       [[ -z "${mybugsdb}" ]] && mybugsdb="bugs"
-       
-       echo -n "mysql bugs dbuser name [bugs]: "; read mybugsuser
-       [[ -z "${mybugsuser}" ]] && mybugsuser="bugs"
-
-       echo -n "mysql bugs dbuser password: "; read mybugspwd
-       [[ -z "${mybugspwd}" ]] && die "Error: no dbuser password"
-       pw=${mybugspwd//\'/\\\'}
-
-       # let's create a config file for checksetup.pl
-       echo "\$answer{'db_host'} = '\$db_host = \"${mybugshost}\";" > bz.cfg.pl
-       echo "\$db_port = ${mybugsport};" >> bz.cfg.pl
-       echo "\$db_name = \"${mybugsdb}\";" >> bz.cfg.pl
-       echo "\$db_user = \"${mybugsuser}\";';" >> bz.cfg.pl
-       echo "\$answer{'db_pass'} = q[\$db_pass = '${mybugspwd}';];" >> bz.cfg.pl
-       echo "\$answer{'db_sock'} = q[\$db_sock = '/var/run/mysqld/mysqld.sock';];" >> bz.cfg.pl
-
-       # privileges
-       echo "Setting correct privileges for bugzilla mysql connection"
-       echo -n "Please enter login info for user who has grant privileges on ${mybugshost} [${USER}]: "; read adminuser
-       [[ -z ${adminuser} ]] && adminuser="${USER}"
-       if [ "${mybugshost}" != "localhost" ]; then
-               echo -n "Client address for bugzilla (at db side) [$(hostname -f)]: "; read clientaddr
-               [[ -z ${clientaddr} ]] && clientaddr="$(hostname -f)"
-       fi
-       # this will be default for localhost
-       [[ -z ${clientaddr} ]] && clientaddr="${mybugshost}"
-
-       # check the installed mysql version
-       type -p mysql &>/dev/null || die "mysql program not found !  Check your PATH (or did you emerge with --nodeps ?)"
-       mysql_version="`mysql -V | cut -d' ' -f6 | sed -e 's:,$::'`"
-       [[ -z ${mysql_version} ]] && die "mysql version check failed (got '${mysql_version}')"
-       extra_bugzie_privs=""
-       (( ${mysql_version:0:1} < 4 )) && extra_bugzie_privs=",LOCK TABLES,CREATE TEMPORARY TABLES"
-
-       # if $bugshost == localhost, don't specify -h argument, so local socket can be used.
-       host=${mybugshost/localhost}
-       /etc/init.d/mysql restart || die "Could not (re)start mysql!"
-       mysql -u "${adminuser}" "${host:+-h ${host}}" -p \
-               -P "${mybugsport}" \
-               -e "GRANT SELECT,INSERT,UPDATE,DELETE,INDEX,ALTER,CREATE,DROP,REFERENCES${extra_bugzie_privs} ON ${mybugsdb}.* TO '${mybugsuser}'@'${clientaddr}' IDENTIFIED BY '${pw}'; FLUSH PRIVILEGES;" \
-               || die "Error initializing database. Please grant permissions manually. See http://www.bugzilla.org/docs/2.18/html/configuration.html."
-
-       echo "Setting the template for localconfig variables"
-       chmod 755 ./checksetup.pl
-       ./checksetup.pl bz.cfg.pl || exit 1
-
-       echo "Final step: setting all html templates and db tables"
-       ./checksetup.pl || exit 1
-
-       echo -n "Do you want to set a crontab [y/N]" ; read cronyes
-       if [ "${cronyes}+" = "y+" ] ; then 
-               /usr/bin/crontab -u apache ${MY_INSTALLDIR}/bugzilla.cron.tab
-       fi
-
+       sed -e "s|/var/www/bugzilla|${MY_INSTALLDIR}|g" -i ${FILE} || die "sed failed"
 else
-       [[ -z "${MY_INSTALLDIR}" ]] && die "${MY_INSTALLDIR} not found!"
-       rm -f "${FILES}" bz.cfg.pl
+       echo "done"
 fi
index ba8abb222a268876a87d02e5bf24e38cec8af34a..8dabca5e65908291b46c025bcce5c60f6db154e3 100644 (file)
@@ -1,2 +1,7 @@
-Please read the Release Notes, especially if you are upgrading:
+Bugzilla has been installed into ${MY_INSTALLDIR}
+
+To finish the installation, please read
+ http://www.bugzilla.org/docs/2.20/html/installation.html
+
+Also, please read the Release Notes, especially if you are upgrading:
  http://www.bugzilla.org/releases/2.20/release-notes.html
index 4d24f23d0adf5b380ed1654ad63cf15f458111ee..71b0acea2585e5d383b8b5529509b3126ca99a7f 100644 (file)
@@ -2,7 +2,7 @@
 
 FILE="bugzilla.cron.daily bugzilla.cron.tab"
 
-function die () 
+function die ()
 {
        echo
        echo "***"
@@ -12,127 +12,8 @@ function die ()
 }
 
 if [ $1 = "install" ]; then
-
        cd "${MY_INSTALLDIR}" || die "Cannot find install dir ${MY_INSTALLDIR}"
-
-       sed -e "s|/var/www/bugzilla|${MY_INSTALLDIR}|g;" -i ${FILE}
-
-       [[ -a localconfig ]] && die "The following does not work on previous installations, please run checksetup.pl in ${MY_INSTALLDIR}"
-
-       echo
-       echo "Finalizing the installation of bugzilla in ${MY_INSTALLDIR}"
-       echo
-       
-       # config setting
-       echo "Details for the bugzilla database"
-       echo "(This scripts creates the database & user)"
-       echo
-
-       echo "If you want to use Postgres, please enter numeric IP"
-       echo "or the config script will hang"
-       echo -n "bugs db host [127.0.0.1]: "; read mybugshost
-       [[ -z "${mybugshost}" ]] && mybugshost="127.0.0.1"
-
-       echo -n "bugs db driver (mysql or pg) [mysql]: "; read mydriver
-       [[ -z "${mydriver}" ]] && mydriver="mysql"
-
-       if [[ ${mydriver} == "mysql" ]]; then
-               port="3306"
-               granter="root"
-       elif [[ ${mydriver} == "pg" ]]; then
-               port="5432"
-               granter="postgres"
-       else
-               die "Wrong db driver"
-       fi
-       
-       echo -n "bugs db port [${port}]: "; read mybugsport
-       [[ -z "${mybugsport}" ]] && mybugsport="${port}"
-       
-       echo -n "bugs db name [bugs]: "; read mybugsdb
-       [[ -z "${mybugsdb}" ]] && mybugsdb="bugs"
-       
-       echo -n "bugs dbuser name [bugs]: "; read mybugsuser
-       [[ -z "${mybugsuser}" ]] && mybugsuser="bugs"
-
-       echo -n "bugs dbuser password: "; read mybugspwd
-       [[ -z "${mybugspwd}" ]] && die "Error: no dbuser password"
-       pw=${mybugspwd//\'/\\\'}
-       
-       echo -n "your SMTP server [localhost]: "; read mysmtp
-       [[ -z "${mysmtp}" ]] && mysmtp="localhost"
-
-       # let's create a config file for checksetup.pl
-       echo "\$answer{'db_host'} = q[" > bz.cfg.pl
-       echo "\$db_host = '${mybugshost}';" >> bz.cfg.pl
-       echo "\$db_driver = '${mydriver}';" >> bz.cfg.pl
-       echo "\$db_port = ${mybugsport};" >> bz.cfg.pl
-       echo "\$db_name = '${mybugsdb}';" >> bz.cfg.pl
-       echo "\$db_user = '${mybugsuser}';" >> bz.cfg.pl
-       echo "];" >> bz.cfg.pl
-       echo "\$answer{'db_pass'} = q[\$db_pass = '${mybugspwd}';];" >> bz.cfg.pl
-       echo "\$answer{'SMTP_SERVER'} = q['${mysmtp}';];" >> bz.cfg.pl
-       if [[ ${mydriver} == "mysql" ]]; then
-               echo "\$answer{'db_sock'} = q[\$db_sock = '/var/run/mysqld/mysqld.sock';];" >> bz.cfg.pl
-       elif [[ ${mydriver} == "pg" ]]; then
-               echo "\$answer{'db_sock'} = q[\$db_sock = '/tmp/.s.PGSQL.${mybugsport}';];" >> bz.cfg.pl
-       else
-               die "Wrong db driver"
-       fi
-
-       # privileges
-       echo "Setting correct privileges for bugzilla connection"
-       echo -n "Please enter login info for user who has grant privileges on ${mybugshost} [${granter}]: "; read adminuser
-       [[ -z ${adminuser} ]] && adminuser="${granter}"
-       if [ "${mybugshost}" != "127.0.0.1" ]; then
-               echo -n "Client address for bugzilla (at db side) [$(hostname -f)]: "; read clientaddr
-               [[ -z ${clientaddr} ]] && clientaddr="$(hostname -f)"
-       fi
-       # this will be default for localhost
-       [[ -z ${clientaddr} ]] && clientaddr="${mybugshost}"
-
-       if [[ ${mydriver} == "mysql" ]]; then
-
-               # check the installed mysql version
-               type -p mysql &>/dev/null || die "mysql program not found !  Check your PATH (or did you emerge with --nodeps ?)"
-               mysql_version="`mysql -V | cut -d' ' -f6 | sed -e 's:,$::'`"
-               [[ -z ${mysql_version} ]] && die "mysql version check failed (got '${mysql_version}')"
-               extra_bugzie_privs=""
-               (( ${mysql_version:0:1} < 4 )) && extra_bugzie_privs=",LOCK TABLES,CREATE TEMPORARY TABLES"
-
-               # if $bugshost == localhost, don't specify -h argument, so local socket can be used.
-               host=${mybugshost/"127.0.0.1"}
-               /etc/init.d/mysql restart || die "Could not (re)start mysql!"
-               mysql -u "${adminuser}" "${host:+-h ${host}}" -p \
-                       -P "${mybugsport}" \
-                       -e "GRANT SELECT,INSERT,UPDATE,DELETE,INDEX,ALTER,CREATE,DROP,REFERENCES${extra_bugzie_privs} ON ${mybugsdb}.* TO '${mybugsuser}'@'${clientaddr}' IDENTIFIED BY '${pw}'; FLUSH PRIVILEGES;" \
-                       || die "Error initializing database. Please grant permissions manually. See http://www.bugzilla.org/docs/tip/html/configuration.html."
-       
-       elif [[ ${mydriver} == "pg" ]]; then
-               # if $bugshost == localhost, don't specify -h argument, so local socket can be used.
-               host=${mybugshost/"127.0.0.1"}
-               /etc/init.d/postgresql restart || die "Could not (re)start postgresql!"
-               createdb -U "${adminuser}" ${host:+-h ${host}} -W \
-                       -p "${mybugsport}" -O "${mybugsuser}" "${mybugsdb}" \
-                       || die "Error initializing database. Please grant permissions manually. See http://www.bugzilla.org/docs/tip/html/configuration.html."
-
-       else
-               die "Wrong db driver"
-       fi
-       
-       echo "Setting the template for localconfig variables"
-       cd ${MY_INSTALLDIR} || die
-       chmod 755 ./checksetup.pl
-       ./checksetup.pl bz.cfg.pl || exit 1
-
-       echo "Final step: setting all html templates and db tables"
-       ./checksetup.pl || exit 1
-
-       echo -n "Do you want to set a crontab [y/N]" ; read cronyes
-       if [ "${cronyes}+" = "y+" ] ; then 
-               /usr/bin/crontab -u apache ${MY_INSTALLDIR}/bugzilla.cron.tab
-       fi
-
+       sed -e "s|/var/www/bugzilla|${MY_INSTALLDIR}|g" -i ${FILE} || die "sed failed"
 else
        echo "done."
 fi