Add ability to switch to single tenant mode

Here's that pull request I promised with the ability to switch to single tenant mode.
Could we maybe wrap these routes in lambda's and then call those in the constraints or outside of them depending on the config? That way it'll be easier to maintain