使用 nginx 在 Debian 8 上安装 Phusion Passenger 时出现“未知指令”

使用 nginx 在 Debian 8 上安装 Phusion Passenger 时出现“未知指令”

我尝试在已安装 nginx(Debian 默认 nginx 包)的 Debian 8(amd64)上安装 Phusion Passenger。我使用官方安装方法: https://www.phusionpassenger.com/documentation/Users%20guide%20Nginx.html#install_on_debian_ubuntu

apt-get install nginx-extras passenger添加后

passenger_root /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini;

/etc/nginx/nginx.conf文件并尝试service nginx restart。重启失败并出现以下错误:

Mai 29 13:20:52 nassau nginx[12880]: nginx: [emerg] unknown directive "pass...32
Mai 29 13:20:52 nassau nginx[12880]: nginx: configuration file /etc/nginx/n...ed
Mai 29 13:20:52 nassau systemd[1]: nginx.service: control process exited, c...=1
Mai 29 13:20:52 nassau systemd[1]: Failed to start A high performance web s...r.
Mai 29 13:20:52 nassau systemd[1]: Unit nginx.service entered failed state.

杂项:

root@nassau:~# apt-cache policy nginx-extras
nginx-extras:
  Installed: 1.6.2-5
  Candidate: 1.6.2-5
  Version table:
     1:1.6.3-8.5.0.8~jessie1 0
        500 https://oss-binaries.phusionpassenger.com/apt/passenger/ jessie/main amd64 Packages
 *** 1.6.2-5 0
        700 http://ftp.debian.org/debian/ jessie/main amd64 Packages
        100 /var/lib/dpkg/status
root@nassau:~# 

我遗漏了什么?我该如何让它工作?

相关内容