For more up-to-date Nginx versions, it is a good idea to add official Nginx package source URLs.
As Nginx releases are signed using PGP you need to download
its PGP key and then add it to
apt-key add nginx_signing.key
/etc/apt/source.list the appropriate package source URL
depending on your OS version, e.g. for Trusty
deb http://nginx.org/packages/ubuntu/ trusty nginx deb-src http://nginx.org/packages/ubuntu/ trusty nginx
Finally, install Nginx.
apt-get install nginx
My Tech Newsletter
Get emails from me about programming & web development. I usually send it once a month