Created
February 7, 2011 02:11
-
-
Save cammerman/813921 to your computer and use it in GitHub Desktop.
Install bootstrapper v2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.ServiceProcess; | |
using System.Configuration.Install; | |
using Autofac; | |
namespace HelloSvc | |
{ | |
using Install; | |
internal class InstallBootstrapper | |
{ | |
public IContainer Build() | |
{ | |
var builder = new ContainerBuilder(); | |
builder | |
.RegisterType<HelloServiceProcessInstaller>() | |
.As<Installer>() | |
.InstancePerLifetimeScope(); | |
builder | |
.RegisterType<Services.GreetServiceInstaller>() | |
.As<Installer>() | |
.InstancePerLifetimeScope(); | |
return builder.Build(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment