Skip to content

Instantly share code, notes, and snippets.

@sshibani
Last active October 9, 2015 13:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sshibani/0000a816f3d9401a5868 to your computer and use it in GitHub Desktop.
Save sshibani/0000a816f3d9401a5868 to your computer and use it in GitHub Desktop.
Sample Startup.cs for DD4T.RestService.WebApi
using Microsoft.Owin;
using Owin;
using DD4T.RestService.WebApi;
using Autofac;
using Autofac.Integration.WebApi;
[assembly: OwinStartup(typeof(MyDD4T.RestService.Startup))]
namespace MyDD4T.RestService
{
public class Startup
{
public void Configuration(IAppBuilder app)
{
log4net.Config.XmlConfigurator.Configure();
var builder = new ContainerBuilder();
builder.RegisterApiControllers(typeof(Startup).Assembly);
app.UseDD4TWebApi(builder);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment