stlyz3's picture

Does the Django appliance allow for more than one Django website?  Out of the box, it seems configured for one but I wanted to host more than one, potentially.  Also, is the appliance ready for production out of the box?

Forum: 
Alon Swartz's picture

Firstly, sorry for the late reply, been busy with business as well as personal stuff - got married :)

Lets first get the Django terminology out of the way:
Projects vs. apps

An app is a Web application that does something -- e.g., a weblog system,
a database of public records or a simple poll app. A project is a collection
of configuration and apps for a particular Web site. A project can 
contain multiple apps. An app can be in multiple projects.
The django appliance is already set up with a "project" ready to hold your apps - located at /var/www/django-sites/apps.

Creating apps in the project are as simple as changing into the /var/www/django-sites/apps directory and running:
./manage.py startapp new_appname

If what you want is to host multiple projects, you will have to update the webserver configuration at /etc/apache2/sites-available/django-sites. I have never setup multiple projects on the same server before, but shouldn't be too difficult with a bit of tinkering.

I hope the above helps, if you have any problems let us know and be as verbose as possible.

Regarding your second question about whether TurnKey Appliances are ready for production, please take a look at liraz's comments 136 and 137 on the subject.

Add new comment