Installation is straight forward : apt-get install nginx

Main configuration file is /etc/nginx/nginx.conf which is has includes to other config files such as /etc/nginx/sites-enabled/default. Added the proxy_pass entry in the location block to the first server and added the second server block to have nginx listen on 8080. So the first server listening at 80 is a proxy for the second listening at 8080 (or vice versa ?)

http {
server {
#server_name localhost;
location / {
proxy_pass http://localhost:8080;
}
}
server {
server_name www.hostname.com;
listen 8080;
root /path/to/root/dir;
location /{
}
}
...
}