Django wsgi apache Deploy project

29 views
Skip to first unread message

N'BE SORO

unread,
May 7, 2019, 9:58:09 AM5/7/19
to Django users

Hi I'm a beginner in python and I realized a project in Django. I have problems in hosting my project. here is my code in the 000-default.conf <VirtualHost *: 80> #ServerName #ServerAlias ServerAdmin webmaster @ localhost DocumentRoot / var / www / html / ecommerce WSGIScriptAlias ​​/ /var/www/html/ecommerce/ecommerce/wsgi.py WSGIPythonPath / var / www / html / ecommerce / ErrorLog $ {APACHE_LOG_DIR} /error.log CustomLog $ {APACHE_LOG_DIR} /access.log combined </ VirtualHost> and I have this error Invalid command 'WSGIScriptAlias / /var / www / html / ecommerce / ecommerce / wsgi.py ', perhaps misspelled or d efined by a module not included in the server configuration

Kevin Jay

unread,
May 7, 2019, 12:42:29 PM5/7/19
to django...@googlegroups.com
Remove the spaces in the paths:

WSGIPythonPath / var / www / html / ecommerce /
should be
WSGIPythonPath  /var/www/html/ecommerce/

Do the same for the other paths

On Tue, May 7, 2019 at 8:57 AM N'BE SORO <soro...@gmail.com> wrote:

Hi I'm a beginner in python and I realized a project in Django. I have problems in hosting my project. here is my code in the 000-default.conf <VirtualHost *: 80> #ServerName #ServerAlias ServerAdmin webmaster @ localhost DocumentRoot / var / www / html / ecommerce WSGIScriptAlias ​​/ /var/www/html/ecommerce/ecommerce/wsgi.py WSGIPythonPath / var / www / html / ecommerce / ErrorLog $ {APACHE_LOG_DIR} /error.log CustomLog $ {APACHE_LOG_DIR} /access.log combined </ VirtualHost> and I have this error Invalid command 'WSGIScriptAlias / /var / www / html / ecommerce / ecommerce / wsgi.py ', perhaps misspelled or d efined by a module not included in the server configuration

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/1912bcdc-cb2f-45a2-932c-d579eb944c0a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Subhodeep Das

unread,
May 7, 2019, 2:49:38 PM5/7/19
to django...@googlegroups.com

Try:

WSGIScriptAlias /test/tc-test /var/www/stage/hello/tc-test/django.wsgi

You shouldn't have trailing slash on first argument.


On Tue, May 7, 2019 at 7:27 PM N'BE SORO <soro...@gmail.com> wrote:

Hi I'm a beginner in python and I realized a project in Django. I have problems in hosting my project. here is my code in the 000-default.conf <VirtualHost *: 80> #ServerName #ServerAlias ServerAdmin webmaster @ localhost DocumentRoot / var / www / html / ecommerce WSGIScriptAlias ​​/ /var/www/html/ecommerce/ecommerce/wsgi.py WSGIPythonPath / var / www / html / ecommerce / ErrorLog $ {APACHE_LOG_DIR} /error.log CustomLog $ {APACHE_LOG_DIR} /access.log combined </ VirtualHost> and I have this error Invalid command 'WSGIScriptAlias / /var / www / html / ecommerce / ecommerce / wsgi.py ', perhaps misspelled or d efined by a module not included in the server configuration

--

N'BE SORO

unread,
May 30, 2019, 5:38:36 AM5/30/19
to django...@googlegroups.com
 thank you everyone I managed the deployment

Reply all
Reply to author
Forward
0 new messages