开发者

Deploy custom .NET Windows Service via Group Policy

I have a Windows Service packaged to MSI that I would like to deploy (unattended) to a number of workstations.

According to the following question on ServerFault: Installing MSI via Group Policy in a Fully Unattended Way you can do that, but the problem is how to pass the properties. The only property I need to pass is the connection string to the main SQL database.

How can I cr开发者_开发技巧eate (with Visual Studio 2010) such a Windows service with MSI that can be installed via Group Policy in a fully unattended way?

UPDATE: It does not have to be Group Policy, we can use any other Windows based technology if available.


You cannot pass in parameters to MSI files installed via Group Policy Software Installation. Not directly. The supported way is to create MSI transform. Load you MSI in Orca, create new transform, modify parameters that are available and save it in .mst file. Then when you create new application package in GPO, use Transforms tab to specify the transform you created.


To install services you can use ServiceInstall and ServiceControl tables:

This is done automatically based on what you set in these tables. I don't think you can configure them in Visual Studio, but you can try WiX.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜