Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

There’s some Win32 stuff you can hook into with your code for service management. These are things like service startup, shutdown, pause and resume. I can’t speak to the Win32 stuff, but .NET abstracts this and you just override a base class to hook into the service stuff. Windows then has a command `sc` to register your EXE as a service and then configure things like auto-start and service restarts. Alternatively, MSI’s can be crafted to configure your EXE as a service at install time.

IMO a lot of parts of Windows are a pain to develop on compared to Linux, but creating and managing services are one of the better/smoother parts.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: