add middleware for wsgi routing with subdomain