• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Install Django

Can you explain in a little bit more details what do you mean under "doesn't work"? Do you see some error in a browser? Do you see blank page in a browser? Some error occurs during configuration?
 
Also make sure that your have Django app itself. The tutorial explains on how setup the environment, not about how to create Django app itself.
 
It seems that you have a wrong document root and also you make a request to a wrong URL.
If you follow the instructions in the article, then you should access your app by the URL that looks like something like following: http://django.main-domain/ (django is a name of subdomain for "main-domain" in such case).
Neither django-app, nor passenger_wsgi.py should present in the URL. Document root of your domain should point to public directory with static content (e.g. django-public directory as described in the article). The app itself and passenger_wsgi.py are located outside the document root and could not be accessed directly.
 
Yes I undestand, I see blank page in a browser, I create the site in two ways, the first way I follow step by step tutorial, the second way I write the tutorial in a folder inside the main domain. but not work!!
 
What is your document root for that domain (please show the name of the directory)?
What is the output of the following command (via ssh inside django-app directory): find ./ -maxdepth 4 -type d
 
/var/www/vhosts/vps51220.vps.ovh.ca# find ./ -maxdepth 4 -type d

./logs/django.vps51220.vps.ovh.ca

./django-app
./django-app/django-public
./django-app/django-public/static
./django-app/django-public/static/admin
./django-app/app
./django-app/app/app
./django-app/tmp
./django-app/django-app-venv
./django-app/django-app-venv/lib
./django-app/django-app-venv/lib/python2.7
./django-app/django-app-venv/bin
./django-app/django-app-venv/local
./django-app/django-app-venv/include
 
I see at least one problem. One need to do the following:
mv ./django-app/app/app ./django-app/app-new
rm -rf ./django-app/app/
mv ./django-app/app-new ./django-app/app
 
> the problem in my browser is 502 Bad Gateway ngix
Are you sure? See no errors produced by Phusion Passenger? :)
 
> the problem in my browser is 502 Bad Gateway ngix
Are you sure? See no errors produced by Phusion Passenger?:)
--
That error is showed when I did the tutorial inside of folder the Apache
 
I guess that you did some steps under the root user. This produced the wrong permissions on a lot of directories.
Proper ways is to allow shell access to system user of domain. And log in via ssh using this user, not root. It also means that you should perform the virtualenv installation, django installation and app installation using this sys user (not root once again).
 
Back
Top