InstallUtil.exe: As others have stated, InstallUtil.exe is intended for development use only, not for final distribution of your service.
MSI: The normal way to deploy services in the fashion you describe (with a proper entry in add/remove programs) would be to use an MSI installer created using a tool designed to help you do so (it is not advisable to “roll your own” tool to do this).
Ad-Hoc: The ad-hoc description of deployment tools below was written in a hurry, and has sort of been re-purposed as a general description of
such tools. Not too relevant for the question asked, but it sort of “happened” and here it is.
Free MSI Tools / Viewers
How can I compare the content of two (or more) MSI files? (towards bottom) – (most of) these are not full-featured tools to make setups, but great to inspect MSI files and to create transforms.
MSI Tools: Short-List
There are many tools you can use for MSI-creation, for example (arbitrary order – links to Stefan Kruger’s installsite.org below will show further tools, these are just the most common ones):
WiX
– quick download
-
Free, open source framework – excellent, but with a learning curve, hence a few more links.
WiX quick-start tips
(a bit chaotic, strangely upvoted, must be helpful).- WiX’s commercial branch
FireGiant
has a WiX expansion pack (which costs money). - Windows Installer and the creation of WiX (what is the idea behind WiX?).
- How to install and start a Windows Service using WiX.
- Documentation: ServiceInstall, ServiceControl.
- Untested: How to create a Windows Service MSI Installer Using WiX.
-
- Deployment and MSI expert Chris Painter has his own, free WiX-based tool called
IsWiX
- It can help with WiX’s learning curve and manage WiX source files.
- Also see his IsWiX Tutorials.
- Deployment and MSI expert Chris Painter has his own, free WiX-based tool called
-
The various ways used (and abused) to install Windows Services.
Advanced Installer
– quick download
- Great commercial tool with lots of smarts to help you deliver packages quickly and reliably.
- Some free features.
- Here is a great gateway to all things Advanced Installer.
- installing services, how-to.
InstallShield
– quick download
- The old and established market leader tool Installshield features a very rich set of functionality capable of delivering advanced setup requirements.
- There used to be a Lite version which cost money at one point. Not sure if it is available now.
- There is an InstallShield Limited Edition version. Unsure of its feature set and cost (if any). Does not work with Visual Studio Community editions.
- Installing, Controlling, and Configuring Windows Services.
PACE suite
– quick download
Visual Studio Installer project type
- There is also the Visual Studio Installer project type in Visual Studio (VS 2017 sample).
- I would not really recommend this – especially if you have advanced deployment or automation requirements.
- It is very basic, and there are many severe limitations.
- Install the Visual Studio setup and deployment project template.
Auto-Update?: Various ways to create auto-updating packages.
MSI Tools: Comparisons and Descriptions
What are the above tools like in actual use? Here are some pragmatic observations and summaries:
- How to create windows installer (recommended overview).
- What installation product to use? InstallShield, WiX, Wise, Advanced Installer, etc (an aging, detailed comparison of these major MSI tools – very detailed and “pragmatic”).
Deployment Tools (General)
There are many further tools available to create create installers / setup.exe files of various kinds (not just MSI tools, but general purpose, legacy tools, multi-platform tools, etc…):
Stefan Kruger’s Comprehensive Lists:
- Non-MSI installer tools: http://www.installsite.org/pages/en/tt_nonmsi.htm
- Windows installer tools: http://www.installsite.org/pages/en/msi/authoring.htm
- Sys-admin tools: http://www.installsite.org/pages/en/msi/admins.htm
Other Links:
-
Cross-Platform Installers: Does an universal cross-platform installer exists? (non-MSI tools).
-
dotNetInstaller: There is also the dotNetInstaller Setup Bootstrapper – which I have never used.
-
Here it is on github.com (source).
-
Just a bootstrapper (runs things in sequence for you, and then some), not a development tool as such. I find this tool “a bit weird”.
Some General Links: And there are various other ways to deploy – for example with self-extracting zip archives and stuff like that. Not recommended, but some links:
- Error Creating a 7-zip installer package (7-Zip, iExpress and other self-extractor creators)
- Combine exe and msi file in one installer (recommended)
- Visual Studio 2017 Installer Project – include VC++ 2015 Redistributable (WiX Burn Quick Start)
- Additional Setup in Visual Studio Installer Projects