Module: check_mk
Branch: master
Commit: 239f9504ab479fa8d65092b28f94946fa1f20400
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=239f9504ab479f…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Tue Apr 14 11:38:45 2015 +0200
updated docu for create msi package
---
doc/treasures/windows_msi/README | 2 ++
doc/treasures/windows_msi/build_msi.bat | 6 ++++--
doc/treasures/windows_msi/check_mk_agent_baked.wxs | 19 +++++++++++++------
.../windows_msi/check_mk_agent_vanilla.wxs | 1 +
4 files changed, 20 insertions(+), 8 deletions(-)
diff --git a/doc/treasures/windows_msi/README b/doc/treasures/windows_msi/README
index 2a64e74..59be53b 100644
--- a/doc/treasures/windows_msi/README
+++ b/doc/treasures/windows_msi/README
@@ -11,7 +11,9 @@ Requires
---------------------------------
- A wine environment with the program packages Mono and Wix-Toolset
http://www.go-mono.com/mono-downloads/download.html
+ # Used version 3.2.3:
http://download.mono-project.com/archive/3.2.3/windows-installer/
http://wixtoolset.org/
+ # Get the binary package and put in into "Program Files (x86)/wix"
- A working directory where the msi package is build, containing the files
cmk_InstallDirDlg.wxs # Modified Install Dialog with Install Service Checkbox
diff --git a/doc/treasures/windows_msi/build_msi.bat
b/doc/treasures/windows_msi/build_msi.bat
index 178362a..d6c1625 100644
--- a/doc/treasures/windows_msi/build_msi.bat
+++ b/doc/treasures/windows_msi/build_msi.bat
@@ -1,5 +1,7 @@
"C:\Program Files (x86)\wix\candle.exe" -ext WixUtilExtension
C:\mkmsi\cmk_WixUI_InstallDir.wxs
"C:\Program Files (x86)\wix\candle.exe" -ext WixUtilExtension
C:\mkmsi\cmk_InstallDirDlg.wxs
-"C:\Program Files (x86)\wix\candle.exe" -ext WixUtilExtension
C:\mkmsi\check_mk_agent.wxs
-"C:\Program Files (x86)\wix\light.exe" -ext WixUIExtension -ext
WixUtilExtension -sval -o check_mk_agent.msi C:\mkmsi\check_mk_agent.wixobj
C:\mkmsi\cmk_WixUI_InstallDir.wixobj C:\mkmsi\cmk_InstallDirDlg.wixobj
+"C:\Program Files (x86)\wix\candle.exe" -ext WixUtilExtension
C:\mkmsi\check_mk_agent_baked.wxs
+"C:\Program Files (x86)\wix\candle.exe" -ext WixUtilExtension
C:\mkmsi\check_mk_agent_vanilla.wxs
+"C:\Program Files (x86)\wix\light.exe" -ext WixUIExtension -ext
WixUtilExtension -sval -o check_mk_agent_baked.msi C:\mkmsi\check_mk_agent_baked.wixobj
C:\mkmsi\cmk_WixUI_InstallDir.wixobj C:\mkmsi\cmk_InstallDirDlg.wixobj
+"C:\Program Files (x86)\wix\light.exe" -ext WixUIExtension -ext
WixUtilExtension -sval -o check_mk_agent_vanilla.msi
C:\mkmsi\check_mk_agent_vanilla.wixobj C:\mkmsi\cmk_WixUI_InstallDir.wixobj
C:\mkmsi\cmk_InstallDirDlg.wixobj
@pause
diff --git a/doc/treasures/windows_msi/check_mk_agent_baked.wxs
b/doc/treasures/windows_msi/check_mk_agent_baked.wxs
index b473ede..bb11169 100644
--- a/doc/treasures/windows_msi/check_mk_agent_baked.wxs
+++ b/doc/treasures/windows_msi/check_mk_agent_baked.wxs
@@ -2,14 +2,20 @@
<?define CompanyName = "Mathias Kettner GmbH"?>
<?define ProductVersion = "1.2.5"?>
<?define ProductUpgradeCode = "854bb2c1-f4aa-4c5c-89e4-8fb0bdfb9ee4"?>
+<?define PackageCode = "47ED1918-CEDF-4D37-943C-B4DBC3F58E6C"?>
<Wix
xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:util='http://schemas.microsoft.com/wix/UtilExtension'>
<Product Id="*" UpgradeCode="$(var.ProductUpgradeCode)"
Name="Check_MK Agent MSI" Version="$(var.ProductVersion)"
Manufacturer="Mathias Kettner GmbH" Language="1033">
- <Package InstallerVersion="200" Platform="x86"
Compressed="yes" Description="Check_MK 32/64 bit MSI installer"/>
+ <Package Id="$(var.PackageCode)" InstallerVersion="200"
Platform="x86" Compressed="yes" Description="Check_MK 32/64 bit
MSI installer"/>
<Media Id="1" Cabinet="product.cab"
CompressionLevel="none" EmbedCab="yes"/>
+
+ <Property Id="ALLUSERS" Value="1" />
+ <Property Id="REINSTALLMODE" Value="amus" />
+ <MajorUpgrade AllowDowngrades="yes" />
+
<Upgrade Id="$(var.ProductUpgradeCode)">
<UpgradeVersion Minimum="$(var.ProductVersion)"
Property="NEWERVERSIONDETECTED"/>
@@ -66,6 +72,11 @@
Execute ="immediate"
Return ="ignore"/>
+ <CustomAction Id="uninstall_plugins"
+ Directory ="INSTALLDIR"
+ ExeCommand='[INSTALLDIR]uninstall_plugins.bat'
+ Execute ="immediate"
+ Return ="ignore"/>
<CustomAction Id="start_service"
Directory ="INSTALLDIR"
@@ -87,6 +98,7 @@
<InstallExecuteSequence>
<Custom Action="stop_service"
After="InstallInitialize">REMOVE="ALL"</Custom>
<Custom Action='uninstall_service'
After='InstallInitialize'>REMOVE="ALL"</Custom>
+ <Custom Action='uninstall_plugins'
After='InstallInitialize'>REMOVE="ALL"</Custom>
</InstallExecuteSequence>
<DirectoryRef Id="INSTALLDIR">
@@ -123,11 +135,6 @@
</Component>
</DirectoryRef>
-
- <InstallExecuteSequence>
- <RemoveExistingProducts Before="InstallInitialize"/>
- </InstallExecuteSequence>
-
<Feature Id="Agent" Level="1">
<ComponentRef Id="agent32"/>
<ComponentRef Id="agent64"/>
diff --git a/doc/treasures/windows_msi/check_mk_agent_vanilla.wxs
b/doc/treasures/windows_msi/check_mk_agent_vanilla.wxs
index bde619a..0bfcfae 100644
--- a/doc/treasures/windows_msi/check_mk_agent_vanilla.wxs
+++ b/doc/treasures/windows_msi/check_mk_agent_vanilla.wxs
@@ -12,6 +12,7 @@
<Package Id="$(var.PackageCode)" InstallerVersion="200"
Platform="x86" Compressed="yes" Description="Check_MK 32/64 bit
MSI installer"/>
<Media Id="1" Cabinet="product.cab"
CompressionLevel="none" EmbedCab="yes"/>
+ <Property Id="ALLUSERS" Value="1" />
<Property Id="REINSTALLMODE" Value="amus" />
<MajorUpgrade AllowDowngrades="yes" />