Support proxying the server in a subfolder

I tried to use Server.js behind a proxy, and I had some problems because the baseURL option was not taken into account everywhere it should be.  This is an attempt to fix that.
WARNING: I'm a beginner in Node, so this might not be the best way to do it. Especially, I dont' know how to run the tests... I merely tried the changes on my server and it seems to work.