在 Debian 9 上使用 Passenger 安装 nginx 时出错

在 Debian 9 上使用 Passenger 安装 nginx 时出错

我正在将 Debian 安装升级到版本 9,但在运行带有 Passenger 的 nginx 时遇到了问题。问题在于尝试安装libnginx-mod-http-passenger,具体来说,它似乎需要比标准 Debian 存储库中更低版本的 nginx:

# sudo apt-get install -y libnginx-mod-http-passenger
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libnginx-mod-http-passenger : Depends: nginx-common (< 1.10.4) but 1.14.2-1~dotdeb+8.1 is to be installed
E: Unable to correct problems, you have held broken packages.

我的乘客来源清单如下:

# cat /etc/apt/sources.list.d/passenger.list
deb https://oss-binaries.phusionpassenger.com/apt/passenger stretch main

我明确想要从存储库安装。那么,我该如何解决这个问题?

答案1

我最终解决了这个问题,尽管不是完全按照我想要的方式。

我删除并清除了所有nginx*软件包libnginx*,然后明确安装了版本 1.10。现在libnginx-mod-http-passenger安装正确,一切正常。

我仍然不太清楚为什么它尝试安装版本1.14.2-1~dotdeb+8.1,因为我使用的是 Debian 9,而不是 8 - 但现在我有版本1.10.3-1+deb9u2

相关内容