Backport osl-apache vhost fixes into osl-nginx

This imports much of the work done in ``osl-apache`` into nginx. That way we're basically using the same type of definition between either http server.
Parses fine on github. What's the issue?