Quantcast
Channel: BitNami Answers - latest questions
Viewing all articles
Browse latest Browse all 2052

Trouble viewing Django app after starting Apache

$
0
0

Just set up a 64 bit ubuntu EC2 instance using the Bitnami DjangoStack image.

So far I have installed a few python dependencies and removed the Project django app which was created by default. I created a new app with 'django-admin.py startproject projectname'. I then followed the instructions here: http://wiki.bitnami.org/Components/Django, attempting to setup apache.

Here is my projectname.conf file:

Alias /static "/opt/bitnami/apps/django/lib/python2.7/site-packages/django/contrib/admin/static"

<Directory '/opt/bitnami/apps/django/lib/python2.7/site-packages/django/contrib/'>
Order allow,deny
Allow from all
</Directory>

WSGIScriptAlias /URL_mount_point "/opt/bitnami/apps/django/scripts/projectname.wsgi"

<Directory '/opt/bitnami/apps/django/scripts'>
Order allow,deny
Allow from all
</Directory>

Here is my projectname.wsgi

import os, sys
sys.path.append('/opt/bitnami/apps/django/django_projects')
sys.path.append('/opt/bitnami/apps/django/django_projects/projectname')
os.environ['DJANGO_SETTINGS_MODULE'] = 'projectname.settings'

import django.core.handlers.wsgi

application = django.core.handlers.wsgi.WSGIHandler()

Here are the last three lines of my httpd.conf:

Include "/opt/bitnami/apache2/conf/ssi.conf"
Include "/opt/bitnami/apache2/conf/bitnami/httpd.conf"
Include "/opt/bitnami/apps/django/conf/projectname.conf"

After doing this and restarting apache, hitting mydomain.com/projectname still comes up with a 404 (the Bitnami landing page comes up just fine at mydomain.com).

Am I missing something here? Are my paths in projectname.wsgi incorrect (I have not strayed from the default Bitnami directory structure). Or is there some additional step I am missing here?


Viewing all articles
Browse latest Browse all 2052

Trending Articles