使用Passenger + Apache2服务Python应用程序

时间:2018-09-13 12:22:52

标签: apache passenger

我试图使用Apache2和Passanger为Python应用程序提供服务,所以我将启用网站的文件更新为以下内容:

<VirtualHost *:5000>
    ServerName mydomain.com

    # Tell Apache and Passenger where your app's code directory is
    DocumentRoot /var/www/html/safepark/safepark
    PassengerAppRoot /var/www/html/safepark

    # Tell Passenger that your app is a Python app
    PassengerAppType wsgi
    PassengerStartupFile passenger_wsgi.py

    # Relax Apache security settings
    <Directory /var/www/html/safepark/safepark>
      Allow from all
      Options -MultiViews
      # Uncomment this if you're on Apache >= 2.4:
      Require all granted
    </Directory>
</VirtualHost>

但是尝试访问safepark应用程序时,我收到“无法访问此网站”

0 个答案:

没有答案