Remove mod-python in favor of mod-wsgi.
mod-python has been deprecated for a while and our current distro of
Django doesn't support it anymore. Moving us to use wsgi completely.
Pull in bits from:
https://github.com/autotest/autotest/commit/ee3cced1afb6bc45216c7038472827ad4033c3f5
Pull in change to db/backends/afe/base.py to fixes readonly db
connection issues.
TEST=setup_dev_autotest.sh and moved our development server to
modpython.
BUG=chromium:217194
Change-Id: Ic3306700e07c7000b2451a576554810d8a6bf7f2
Reviewed-on: https://gerrit.chromium.org/gerrit/50656
Tested-by: Scott Zawalski <scottz@chromium.org>
Reviewed-by: Simran Basi <sbasi@chromium.org>
Commit-Queue: Scott Zawalski <scottz@chromium.org>
Reviewed-by: Scott Zawalski <scottz@chromium.org>
diff --git a/site_utils/setup_dev_autotest.sh b/site_utils/setup_dev_autotest.sh
index f3b39d9..5ab8c06 100755
--- a/site_utils/setup_dev_autotest.sh
+++ b/site_utils/setup_dev_autotest.sh
@@ -104,7 +104,7 @@
fi
echo "Installing needed Ubuntu packages..."
-PKG_LIST="mysql-server mysql-common libapache2-mod-python python-mysqldb \
+PKG_LIST="mysql-server mysql-common libapache2-mod-wsgi python-mysqldb \
gnuplot apache2-mpm-prefork unzip python-imaging libpng12-dev libfreetype6-dev \
sqlite3 python-pysqlite2 git-core pbzip2 openjdk-6-jre openjdk-6-jdk \
python-crypto python-dev subversion build-essential python-setuptools \
@@ -198,8 +198,10 @@
sudo a2ensite autotest-server
# Enable rewrite module
sudo a2enmod rewrite
-# Enable mod-python
-sudo a2enmod python
+# Enable wsgi
+sudo a2enmod wsgi
+# enable version
+sudo a2enmod version
# Setup permissions so that Apache web user can read the proper files.
chmod -R o+r "${AT_DIR}"
find "${AT_DIR}"/ -type d -print0 | xargs --null chmod o+x