-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Provide the WinSW service manager WinSW is a useful tool that can wrap any application as a Windows service; it provides the boilerplate code for interacting with the service infrastructure on Windows. You define a configuration for your application service in XML, then use WinSW, along with your configuration, as a service controller. The full specification for the service configuration can be found here: https://github.com/winsw/winsw/blob/v3/samples/complete.xml In this initial implementation, we provide support for most of the available elements, with the exception of: * serviceaccount * startarguments (I don't know what the difference is between that and 'arguments') * workingdirectory * logpath and log * env * download * extensions Support for workingdirectory and env will follow in subsequent commits; these fields can be added to the generic `ServiceInstallCtx` since they are common options on all platforms. Most of the code here deals with building the configuration file. This code was written as a separate function so that the different options could be unit tested. There is an integration/system test in a similar fashion to the sc manager. * Extend `ServiceInstallCtx` with new options It is very common to define a working directory for a service process and a list of environment variables to pass to the process when it runs. The `ServiceInstallCtx` is extended for this because it applies to most service managers. In this particular case, three of the managers have been extended to support the variables: Systemd, Launchd and WinSW. The Windows `sc.exe` service manager does not support specifying either. The other two unix-based service managers might, but I am not familiar with those at the present time. It should be easy enough to extend them with a further PR. * Update CHANGELOG for WinSW and `ServiceInstallCtx` changes
- Loading branch information
Showing
13 changed files
with
934 additions
and
35 deletions.
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
Oops, something went wrong.