Step 2

Step 3

Update Ubuntu packages

apt-get update

Step 4

Install latest Nginx

sudo apt-get install nginx

Optionally, if you are upgrading from an older version you would need to remove nginx-full and nginx-common packages as they will conflict with a new version. You would do this before Step 3. If you do upgrade, it’s always good practice to backup your Nginx config files before you upgrade.