简体   繁体   中英

deploy django application on apache server

I'm new to django and deploying apps. I tried to follow this tutorial. Everything worked great except that by the end, instead of the django app I got the depault apache2 page. (If it's matter, I work on ubuntu).

/etc/apache2/sites-available/000-default.conf:

<VirtualHost *:8079>


    Alias /static /home/or/myproject/static
    <Directory /home/or/myproject/static>
        Require all granted
    </Directory>

    <Directory /home/or/myproject/myproject/>
        <Files wsgi.py>
            Require all granted
        </Files>
    </Directory>

    WSGIDaemonProcess myproject python-path=/home/or/myproject/ python-home=/home/or/myproject/myprojectenv
    WSGIProcessGroup myproject
    WSGIScriptAlias / /home/or/myproject/myproject/wsgi.py

</VirtualHost>

Any suggestions? maybe firewall or something? I'm pretty lost...

  [1]: https://www.digitalocean.com/community/tutorials/how-to-serve-django-applications-with-apache-and-mod_wsgi-on-ubuntu-14-04

因此,我不确定出了什么问题,但是我使用了教程,并且效果很好(除了我编辑的是“ 000-default”文件而不是“ default”文件)。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM