I am trying to access a website which I am running with Apache. The issue is that that I get a 403 Error and only land on the Permission Denied error page. The backend etc. itself is using Django.
What I get from the error log:
(13)Permission denied: access to /index/ denied
I also edited the default apache conf to this:
<VirtualHost *:80>
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerM$
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, $
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/acess.log combined
ServerAdmin webmaster@localhost
WSGIDaemonProcess djangoapps python-path=/home/djangoa$
WSGIProcessGroup djangoapps
WSGIScriptAlias / /home/djangoapps/plugit/wsgi.py
<Directory /home/djangoapps/plugit>
<Files wsgi.py>
Require all granted
</Files>
</Directory>
</VirtualHost>
The loaded (I hope) wsgi.py file doesn't include more then the default content yet. I also set www-data:www-data
on everything in the project..
Which OS are you using?? Are you getting root access to your server?? If yes, check if SELinux is disabled or not. If not, then disable it by running setenforce 0
on your server's terminal to disable it.
Q. What is SELinux?
A. Security-Enhanced Linux (SELinux) is a Linux kernel security module (kind of a system firewall) similar to AppArmour.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.