# If you just change the port or add more ports here, you will likely also
#
have to change the VirtualHost statement in
#
/etc/apache2/sites-enabled/000-default.conf
cd var/www/
sudo chmod
-R 644 mysite
sudo find mysite
-type d -exec chmod 755 \{\} \;
sqlite3数据库读写权限:
sudo chgrp www-data mysite
sudo chmod g
+w mysite
sudo chgrp www
-data mysite/db.sqlite3
sudo chmod g
+w mysite/db.sqlite3
8.配置生效
a2ensite mysite.conf
9.启动服务
service apache2 restart
出现错误:
restarting web server apache2 [fail]* The apache2 configtest failed.
Output of config test was:
AH00526: Syntax error on line
8 of /etc/apache2/sites-enabled/mysite.conf:
Invalid command
'WSGIScriptAlias', perhaps misspelled or defined by a module not included in the server configuration
Action
'configtest' failed.
The Apache error log may have more information.
tony@T:
/etc/apache2/sites-available$ sudo a2enmod wsgi
ERROR: Module wsgi does
not exist!