By KuldipPatel
Hello there,
I have been trying to host my web.py simple REST API application and it is somehow not working… PLEASE HELP. Here is my Apache2 config snippet.
<VirtualHost *:80>
ServerAdmin webmaster@MySite.com
DocumentRoot /var/www/mysite
Servername 128.199.241.142
ServerAlias Centos www.MySite.com
WSGIScriptAlias /service /var/www/mysite/MyApp.py/
Alias /static /var/www/mysite/
AddType text/html .py
<Directory /var/www/mysite>
Order deny,allow
Allow from all
# SetHandler wsgi-script
# Options ExecCGI
Options Indexes FollowSymLinks Includes ExecCGI
</Directory>
</VirtualHost>
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Without more information, it’s hard to answer this question. A good first place to look is always the error logs. On Ubuntu, Apache’s can be found at: /var/log/apache2/error.log
When working with mod_wsgi, if you need to dig deeper into why something isn’t working as expected, the “Debugging Techniques” section of its documentation provides a lot of valuable information. Webpy’s own docs on using mod_wsgi may be helpful as well.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.