public UninstallCommand(WinServiceSettings settings, string commandLine, string instance) { _settings = settings; _commandLine = commandLine; if (instance != null) _settings.ServiceName = new ServiceName(_settings.ServiceName.Name, instance); }
private Type _winForm; /// <summary> /// Initializes a new instance of the <see cref="RunnerConfigurator"/> class. /// </summary> private RunnerConfigurator() { _winServiceSettings = new WinServiceSettings(); _credentials = Credentials.LocalSystem; _serviceConfigurators = new List <Func <IService> >(); _runnerAction = NamedAction.Console; _winForm = typeof(ServiceConsole); }
public static Installer[] BuildInstallers(WinServiceSettings settings) { var result = new Installer[] { ConfigureServiceInstaller(settings), ConfigureServiceProcessInstaller(settings) }; return result; }
public static ServiceProcessInstaller ConfigureServiceProcessInstaller(WinServiceSettings settings) { var credentials = settings.Credentials; var installer = new ServiceProcessInstaller { Username = credentials.Username, Password = credentials.Password, Account = credentials.AccountType }; return installer; }
public static ServiceInstaller ConfigureServiceInstaller(WinServiceSettings settings) { var installer = new ServiceInstaller { ServiceName = settings.ServiceName.FullName, Description = settings.Description, DisplayName = settings.FullDisplayName, ServicesDependedOn = settings.Dependencies.ToArray(), StartType = ServiceStartMode.Automatic }; return installer; }
public InstallCommand(WinServiceSettings settings, string commandLine, string instance, string username, string password) { _settings = settings; _commandLine = commandLine; if (username != null && password != null) _settings.Credentials = new Credentials(username, password, ServiceAccount.User); if (instance != null) { _settings.ServiceName = new ServiceName(_settings.ServiceName.Name, instance); } }
public InstallService(WinServiceSettings settings) { _settings = settings; }
public HostServiceInstaller(WinServiceSettings settings) { _settings = settings; }
public UninstallService(WinServiceSettings settings, string commandLine) { _settings = settings; _commandLine = commandLine; }
public ServiceCommand(IServiceCoordinator coordinator, WinServiceSettings settings) { _coordinator = coordinator; _settings = settings; }