Until recently I've been using ppa:nginx/development
but suddenly I can't install the nginx version from there anymore on 14.04.
https://launchpad.net/~nginx/+archive/ubuntu/development also states:
The following releases of Ubuntu are no longer supported in the PPA due to build dependencies or problems which cannot be resolved due to the age of the release:
- Trusty (14.04)
What other options do I have to get a more recent version of nginx on 14.04?
I need at least http2
support (I'm running 1.9 and 1.13 on some machines successfully).
Just an FYI, "NGINX Development" is no longer "Development". The Development branch became the "Mainline" branch, so you should refer to it as such - the PPA's
nginx/development
is because it's an 'old' PPA held over from before they called it Mainline.I've meant to change it but it hasn't been a huge priority so...
Why doesn't the PPA support Trusty 14.04 anymore?
The required dependencies for newer NGINX don't exist on 14.04, and we build only the Debian packages from Debian, not the Ubuntu specific variants. As such, the builds for 14.04 of NGINX packages fail because one or more bits of code in NGINX do not build in the (now over 4 years old) 14.04 code bases.
The build logs show this failure:
... across all architecture builds in 14.04 for the PPA (build logs for 1.15.0:
amd64
,arm64
,armhf
,i386
, andppc64el
). The exact build failure lies in a third party module that ships withnginx-extras
and is in use by a number of individuals. This build failure is not unique to the Mainline branch of NGINX, either, as the same failure happens in the Stable branch. And this build failure only happens in 14.04.This module does not build in 14.04 under any circumstances; as such 14.04 builds fail to complete. I could drop this feature from the package for Trusty, but that would make the packages not consistent across releases.
For this reason, I dropped 14.04 as a supported from the NGINX PPAs.
The PPA used to have an older 1.13.x build in it, why doesn't that work anymore?
As for the PPA no longer having 1.13, that's because routinely (usually once a year at about the same time each year sometime in mid to late July) I go through and clean up the PPAs to remove versions of the package for "Not Supported in the PPA" releases.
This is why the PPA no longer works for 14.04, because I went and cleaned up the packages in the PPA.
(We had a similar issue with Precise back in 2014 where I had to kill off Precise builds for the same reason: older libraries wouldn't build the newer NGINX and module requirements)
Alternative to the PPA: Use NGINX Upstream Repositories
This will not contain nginx-extras or any third party modules such as the Lua module - if you need those you are out of luck.
Now, to get updated NGINX in 14.04, you can try to use the instructions to install the NGINX Upstream Repositories, however in order to do this you have to remove all other NGINX packages first, and make sure you aren't using any third party modules such as Lua
"The Real Problem", or, "Why you should actually upgrade to a newer Ubuntu instead of using 14.04 for newer NGINX":
The primary reason you really should be going and upgrading to a newer Ubuntu instead of trying to use 14.04 is that HTTP/2 on 14.04 will not have all the required features necessary for true HTTP/2 support - namely ALPN support from the OpenSSL libraries.
HTTP/2 needs ALPN support to truly function in the modern age; this is not available from OpenSSL libraries in Ubuntu 14.04. The other mode for HTTP/2 (NPN) is not supported by many browsers, so you won't actually get HTTP/2 support from many libraries now, as many browsers and such do not support NPN HTTP/2.
The only approach which fixes this is upgrade your systems to at least 16.04, as those will provide new enough OpenSSL to enable HTTP/2 support and also will provide you the ability to use newer builds of NGINX as the libraries are newer and the build dependencies to compile newer NGINX and the packages from Debian exist.