Page 1 of 1

on Vesta, how to setup a django website?

Posted: Thu Aug 27, 2015 3:03 pm
by dolacmeo
is there any details about how to setup django on apache2,
I only found the conf of wsgi simple.
and in the simple , found path like:

Code: Select all

python-path=/home/admin/web/buyplus.me/private/django/bala.bala/env/lib/python2.6/site-packages
but nothing in there.

anyone? help plz

Re: on Vesta, how to setup a django website?

Posted: Tue Sep 01, 2015 6:38 pm
by skurudo
And this path do you use correct?

Re: on Vesta, how to setup a django website?

Posted: Fri Jan 29, 2016 12:55 am
by erm3nda
This path does assume you used python virtualenv into that user folder, to enable env/lib/ at that point after you install it's requeriments, of course (in example, django)

Im sure you'll need to tweak the version at all.

Re: on Vesta, how to setup a django website?

Posted: Tue Mar 08, 2016 12:39 pm
by paralosreg
Hello.
I need a little help to deploy a Django application. I use this Apache conf manually.

Code: Select all

<VirtualHost *:80>
    # This is name based virtual hosting. So place an appropriate server name
    #   here. Example: django.devsrv.local
    ServerName  [[SERVER_NAME]]
    ServerAdmin webmaster@localhost

    # This alias makes serving static files possible.
    #   Please note, that this is geared to our settings/common.py
    #   In production environment, you will propably adjust this!
    Alias /static/  {{ project_directory }}/run/static/

    # This alias makes serving media files possible.
    #   Please note, that this is geared to our settings/common.py
    #   In production environment, you will propably adjust this!
    Alias /media/  {{ project_directory }}/run/media/

    # Insert the full path to the wsgi.py-file here
    WSGIScriptAlias /   {{ project_directory }}/{{ project_name }}/wsgi.py

    # PROCESS_NAME specifies a distinct name of this process
    #   see: https://code.google.com/p/modwsgi/wiki/ConfigurationDirectives#WSGIDaemonProcess
    # PATH/TO/PROJECT_ROOT is the full path to your project's root directory, 
    #   containing your project files
    # PATH/TO/VIRTUALENV/ROOT: If you are using a virtualenv specify the full
    #   path to its directory.
    #   Generally you must specify the path to Python's site-packages.
    WSGIDaemonProcess   {{ project_name }}  python-path={{ project_directory }}:{{ project_directory }}/../lib/python2.7/site-packages

    # PROCESS_GROUP specifies a distinct name for the process group
    #   see: https://code.google.com/p/modwsgi/wiki/ConfigurationDirectives#WSGIProcessGroup
    WSGIProcessGroup    {{ project_name }}

    # Serving static files from this directory
    #   Please note, that this is geared to our settings/common.py
    #   In production environment, you will propably adjust this!
    <Directory {{ project_directory }}/run/static>
        Options -Indexes
        Order deny,allow
        Allow from all
    </Directory>

    # Serving media files from this directory
    #   Please note, that this is geared to our settings/common.py
    #   In production environment, you will propably adjust this!
    <Directory {{ project_directory }}/run/media>
        Options -Indexes
        Order deny,allow
        Allow from all
    </Directory>

    LogLevel warn

    # PROJECT_NAME is used to seperate the log files of this application
    ErrorLog    ${APACHE_LOG_DIR}/{{ project_name }}_error.log
    CustomLog   ${APACHE_LOG_DIR}/{{ project_name }}_access.log combined
</VirtualHost>
It would be very interesting to make a tutorial for all newbies like me. I have no idea where copy my django project files with the default VestaCP wsgi configuration.

Re: on Vesta, how to setup a django website?

Posted: Fri Jul 30, 2021 5:28 am
by djangotutslv
Setting up a Django website with Vesta is a task that is best left to the professionals. This article will guide you through the more complicated steps of installing and running your Vesta website on your own without any hassle. Also you can pick Django tutorial also.
1) Install Vagrant
2) Install Virtual Box
3) Download and install latest version of Ubuntu Server or whichever distribution you prefer
4) Clone this repository: git clone https://github.com/astroboycoffee/vesta_site.git
5) Follow the instructions in the readme file in order to run the script

Vesta is a web design company that allows you to create your own website for as little as $5/month. Vesta uses django, python, and other revolutionary technologies to do this.

Vesta can be thought of as a web hosting service with an additional site builder. You can upload your own design templates from the Vesta template marketplace or import them from other sites. Then once you have the website's design set up, Vesta will set up the necessary software on their servers so that you can start building your site!

Re: on Vesta, how to setup a django website?

Posted: Tue Aug 03, 2021 10:37 am
by imperio