Find workaround for module-level mutables

Currently, server.py has a few module-level mutables, as this works better with klein. This needs to be changed, possibly by putting the mutables in a class, and instantiating an instance of that class as a global variable.