Skip to content

Commit

Permalink
msi: configure OpenVPN Service also on reinstall
Browse files Browse the repository at this point in the history
We configure openvpn service (set startup mode and run, if needed)
only on installation or upgrade. This is achieved by running
configuration custom action with "NOT Installed" condition.

However the product may be reinstalled (even though we disable it in UI),
for example when pushed via AD Group Policy or with command line

    msiexec /fomusv "OpenVPN-2.6.2-I001-amd64.msi" /L*V reinstall.log

In this case OpenVPN service status is set to "disabled", since our
configuration custom action won't be run.

Fix by changing action condition to NOT REMOVE, which covers both
install/upgrade and reinstall cases.

Fixes #348

Change-Id: I92974dea4749c415e25ab0f804050e3e6d309ffc
Signed-off-by: Lev Stipakov <[email protected]>
  • Loading branch information
lstipakov committed Apr 5, 2023
1 parent 11a1a12 commit fb60757
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion windows-msi/msi.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@
<InstallExecuteSequence>
<Custom Action="FindSystemInfo" After="FindRelatedProducts"/>
<Custom Action="CheckOpenVPNServiceStatus" After="ProcessComponents"/>
<Custom Action="ConfigureOpenVPNService" After="StartServices">NOT Installed</Custom>
<Custom Action="ConfigureOpenVPNService" After="StartServices">NOT REMOVE</Custom>
<Custom Action="GetInstallDir" After="FindRelatedProducts"/>
<Custom Action="UpdatePlapReg" After="InstallFiles"/>
</InstallExecuteSequence>
Expand Down

0 comments on commit fb60757

Please sign in to comment.