无法在 ubuntu 14.04 中添加 nginx 最新版本的应用程序存储库

Ale*_*lig 6 ubuntu nginx

Ubuntu 默认安装 nginx 1.4.6。我正在尝试安装最新的稳定版 nginx (1.6.2)。所以这里说:

您需要添加 Ubuntu PPA 存储库才能在您的系统上获得最新的 Nginx 稳定版本。使用下面的命令来做到这一点。

# Add repository to your system
# magesh@magesh-desktop:~$ add-apt-repository ppa:nginx/$nginx
Run Code Online (Sandbox Code Playgroud)

但是当我尝试这个命令时它会抛出错误:

Cannot add PPA: 'ppa:nginx/'.
Please check that the PPA name or format is correct.
Run Code Online (Sandbox Code Playgroud)

我该如何解决?

谢谢

Xav*_*cas 12

替换$nginxstable

add-apt-repository ppa:nginx/stable
apt-get update
apt-get install nginx
Run Code Online (Sandbox Code Playgroud)