The Ubuntu repository is excruciating slow at adding updated software and no more is this evident with Nginx which is your servers life blood. At the time of this posting Nginx 1.1.9 is still the release version for Ubuntu 12.04 and there have been 8 stable releases with tons of bug fixes, new features and performance enhancements since. What they are waiting for is beyond me as there are and cannot be any compatibility issues with Nginx and any other Ubuntu software, its not that kind of webserver, its standalone and will work on any OS no matter the version there are no compatibility issues.
So if you want the best of Nginx update to the latest 1.2.7 stable at the time of this posting, with only a few commands in your servers shell. This setup will also upgrade to the latest stable when you update the server as well.
sudo nano /etc/apt/sources.list
Add the following in the file:
# Nginx upgrades deb http://nginx.org/packages/ubuntu/ precise nginx deb-src http://nginx.org/packages/ubuntu/ precise nginx
Now remove the old version on your server:
sudo apt-get clean sudo apt-get remove nginx-*
Get the signing key
wget http://nginx.org/packages/keys/nginx_signing.key cat nginx_signing.key | sudo apt-key add -
And install the latest stable release, hit enter for the default which is to keep your nginx.conf and not install a new one.
sudo apt-get update sudo apt-get upgrade sudo apt-get install nginx
This will remove the old version but keep all your config and vhost files intact, install the latest stable release all without a seconds downtime
Now restart nginx
sudo service nginx restart