views:

145

answers:

3

I've a windows service that I need to install (installutil) every time I debug the application during development. Is there any way I can tweak the Installer/ProjectInstaller classes so that it runs as a console application during debug mode. Something like #if..#endif preprocessors can help?

A: 

Not sure if this helps, but when I write services I write the "worker" part of the service as a DLL and use it from a Winform/console app. I only use an actual service to call into the already tested and stable worker DLL.

Kevin Buchan
+3  A: 

This may help you

Ahmed Said
A: 

Hi! I am a developer for an open source windows service hosting framework called Daemoniq. And debugging windows services as a console application is one of its features. You can download it from http://daemoniq.org

Current features include:

  • container agnostic service location via the CommonServiceLocator
  • set common service properties like serviceName, displayName, description and serviceStartMode via app.config
  • run multiple windows services on the same process
  • set recovery options via app.config
  • set services depended on via app.config
  • set service process credentials via command-line
  • install, uninstall, debug services via command-line

Thanks!

jake.stateresa