public void Configuration(IAppBuilder appBuilder)
        {
            var container = IocConfig.BuildContainer();
            var configuration = WebApiConfig.Register();

            // Register dependency resolver
            configuration.DependencyResolver = new SimpleInjectorWebApiDependencyResolver(container);

            // Configure OAuth
            appBuilder.ConfigureAuthentication(container.GetInstance<OAuthBearerAuthenticationOptions>());
            appBuilder.ConfigureExternalProviders();

            appBuilder.UseCors(CorsOptions.AllowAll);
            appBuilder.UseWebApi(configuration);

            MembershipRebootConfig.Configure();
        }