LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
Search this Thread
Old 07-10-2010, 01:07 PM   #1
cmnorton
Member
 
Registered: Feb 2005
Distribution: Ubuntu, CentOS
Posts: 585

Rep: Reputation: 35
Integrating Django Into Apache


I'm working through Django examples in the Django Visual Quickpro Guide. Those are working out nicely, but I am having trouble integrating this into my Apache server.

Does any one have samples as to how to do this?

The thing that perplexes me the most is the admin site formats nicely using the built-in web server, but displays flat accessing in Apache.

Here's my current apache2.conf config corresponding to the django application:

Listen 8586
<VirtualHost _default_:8586>

<Location "/">
SetHandler python-program
PythonHandler django.core.handlers.modpython
SetEnv DJANGO_SETTINGS_MODULE chapter4.settings
PythonOption django.root /home/amr/web/django/chapter4
PythonPath "['/home/amr/web/django/'] + ['/home/amr/web/django/favorites/'] + sys.path"
PythonDebug On
</Location>
</VirtualHost>
 
Old 09-24-2010, 12:59 PM   #2
cmnorton
Member
 
Registered: Feb 2005
Distribution: Ubuntu, CentOS
Posts: 585

Original Poster
Rep: Reputation: 35
Working Apache Configuration

This works in Apache and for mod_python
Code:
<Location />
        SetHandler python-program
        PythonHandler django.core.handlers.modpython
        SetEnv DJANGO_SETTINGS_MODULE settings
        PythonOption django.root /home/amr/django/amr
        PythonPath "['/home/amr/django', '/home/amr/django/amr', '/usr/local/lib
/site-packages/django'] + sys.path"
        PythonDebug On
</Location>
 
  


Reply

Tags
apache, config, django admin


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Integrating Apache with Tomcat with JK Astral Projection Linux - Server 4 02-25-2010 03:01 AM
Problem integrating PHP to apache R960XT Linux - Software 3 03-05-2007 11:42 AM
Integrating Tomcat with Apache shimommm Linux - Newbie 0 06-01-2006 07:29 AM
Integrating PHP and MySQL Into Apache From Full Installation tsuehpsyde Fedora 11 05-05-2004 02:15 PM
integrating WEBDAV and LDAP apache modules jasongonella Linux - Networking 0 10-30-2001 04:51 AM


All times are GMT -5. The time now is 08:09 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration