Hossein Torabi
Hossein Torabi

Reputation: 33

Deploying Django Project with apache2

Someone can help me why it doesn't work? (my project name is ikh) i'm using ubuntu 16.04 LTS, Apache2 , Python3

ServerAdmin webmaster@localhost
DocumentRoot /var/www/ikh

WSGIDaemonProcess ikh python-path=/var/www/ikh/  python-home=/var/www/ikh/.env
WSGIProcessGroup ikh
WSGIScriptAlias / /var/www/ikh/ikh/wsgi.py

<Directory /var/www/ikh/ikh>
    <Files wsgi.py>
        Require all granted
    </Files>
</Directory>



ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined

Upvotes: 1

Views: 36

Answers (1)

Hossein Torabi
Hossein Torabi

Reputation: 33

i found that some interesting problems :

1 - first should set server to listen the port that i want to deploy on it!

Listen 8000

2 - to use WSGIDaemonProcess should do like this sample that i write it for my apache2 configuration

WSGIDaemonProcess ikh python-path=/var/www/ikh  python-home=/var/www/ikh/env/lib/python3.5/site-packages

and thats about it!

Upvotes: 1

Related Questions