Have you come across Rumpkernel? I'd recommend looking at that since it can work with legacy code. There's a static-website tutorial that describes how to use Nginx as a unikernel.
https://github.com/rumpkernel/wiki/wiki/Tutorial%3A-Serve-a-...
https://github.com/rumpkernel/wiki/wiki/Tutorial%3A-Serve-a-...