Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Ubuntu machine.

Installed mod_python using apt-get.

added

   <Directory /var/www/>
            Options Indexes FollowSymLinks MultiViews
            AllowOverride None
            Order allow,deny
            allow from all  
            AddHandler mod_python .py
            PythonHandler mod_python.publisher
            PythonDebug On
    </Directory>

to the sites-available/default file.

Restarted Apache.

But I still do not see Python running. Instead the browser starts downloading the file.

share|improve this question
    
Think about using code.google.com/p/modwsgi instead. –  bernie Aug 10 '10 at 5:48
    
I still have no clue what is wrong with what I am doing. I was wondering if modwsgi has some advangates over mod_python when it comes to installing using Django. –  sabertooth Aug 11 '10 at 1:16

1 Answer 1

up vote 1 down vote accepted

Got it!

PythonHandler mod_python.publisher 

needs to be

PythonHandler mod_python.cgihandler

Then you can run Python as CGI.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.