Added Wix based installer
This commit is contained in:
72
TimberWix/Product.wxs
Normal file
72
TimberWix/Product.wxs
Normal file
@@ -0,0 +1,72 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||
<Product Id="*" Name="TimberWinR" Language="1033" Version="1.0.0.0" Manufacturer="Vistaprint" UpgradeCode="5c2b6a95-34d5-4131-8fb0-5c97214df942">
|
||||
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
|
||||
<Property Id="CONFIGFILE">default.json</Property>
|
||||
<Property Id="LOGDIR">c:\logs</Property>
|
||||
<Property Id="LOGLEVEL">Info</Property>
|
||||
<MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />
|
||||
<MediaTemplate EmbedCab="yes" />
|
||||
|
||||
<Feature Id="ProductFeature" Title="TimberWinR" Level="1">
|
||||
<ComponentGroupRef Id="ProductComponents" />
|
||||
</Feature>
|
||||
</Product>
|
||||
|
||||
<Fragment>
|
||||
<Directory Id="TARGETDIR" Name="SourceDir">
|
||||
<Directory Id="ProgramFilesFolder">
|
||||
<Directory Id="INSTALLFOLDER" Name="TimberWinR" />
|
||||
</Directory>
|
||||
</Directory>
|
||||
</Fragment>
|
||||
|
||||
<Fragment>
|
||||
<ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
|
||||
<Component Id="ProductComponent" Guid="1BDEC5F3-5E9F-4E2E-8B1B-30E7968A99E1">
|
||||
<File Id="TimberWinR.ServiceHost.exe" Name="$(var.TimberWinR.ServiceHost.TargetFileName)" Source="$(var.TimberWinR.ServiceHost.TargetPath)" />
|
||||
<File Id="TimberWinR.ServiceHost.exe.config" Source="$(var.TimberWinR.ServiceHost.TargetDir)\TimberWinR.ServiceHost.exe.config" />
|
||||
<File Id="Interop.MSUtil.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\Interop.MSUtil.dll" />
|
||||
<File Id="csredis.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\csredis.dll" />
|
||||
<File Id="Newtonsoft.Json.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\Newtonsoft.Json.dll" />
|
||||
<File Id="Nlog.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\Nlog.dll" />
|
||||
<File Id="RestSharp.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\RestSharp.dll" />
|
||||
<File Id="RapidRegex.Core.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\RapidRegex.Core.dll" />
|
||||
<File Id="TimberWinR.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\TimberWinR.dll" />
|
||||
<File Id="Topshelf.dll" Source="$(var.TimberWinR.ServiceHost.TargetDir)\Topshelf.dll" />
|
||||
</Component>
|
||||
</ComponentGroup>
|
||||
|
||||
<InstallExecuteSequence>
|
||||
<Custom Action='ManagedInstall' After="InstallFiles">NOT Installed</Custom>
|
||||
<Custom Action='ManagedInstall2' After="ManagedInstall">NOT Installed</Custom>
|
||||
<Custom Action='ManagedUnInstall' Before="RemoveFiles">Installed</Custom>
|
||||
</InstallExecuteSequence>
|
||||
|
||||
<CustomAction Id="ManagedInstall"
|
||||
Directory="INSTALLFOLDER"
|
||||
Impersonate="yes"
|
||||
Execute="deferred"
|
||||
ExeCommand='"[INSTALLFOLDER]TimberWinR.ServiceHost.exe" install --autostart -configFile "[CONFIGFILE]" -logDir "[LOGDIR]" -logLevel "[LOGLEVEL]"'
|
||||
Return='check'>
|
||||
</CustomAction>
|
||||
|
||||
<CustomAction Id="ManagedInstall2"
|
||||
Directory="INSTALLFOLDER"
|
||||
Impersonate="yes"
|
||||
Execute="deferred"
|
||||
ExeCommand='"[INSTALLFOLDER]TimberWinR.ServiceHost.exe" start'
|
||||
Return='check'>
|
||||
</CustomAction>
|
||||
|
||||
<CustomAction Id="ManagedUnInstall"
|
||||
Directory="INSTALLFOLDER"
|
||||
Impersonate="yes"
|
||||
Execute="deferred"
|
||||
ExeCommand='"[INSTALLFOLDER]TimberWinR.ServiceHost.exe" uninstall'
|
||||
Return='check'>
|
||||
</CustomAction>
|
||||
|
||||
|
||||
</Fragment>
|
||||
</Wix>
|
||||
60
TimberWix/TimberWinR.Wix.wixproj
Normal file
60
TimberWix/TimberWinR.Wix.wixproj
Normal file
@@ -0,0 +1,60 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
|
||||
<ProductVersion>3.8</ProductVersion>
|
||||
<MSIVersionNumber>1.1.0</MSIVersionNumber>
|
||||
<ProjectGuid>82a39b31-61ec-468d-aa71-0d949ac6528f</ProjectGuid>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<OutputName>TimberWinR-$(MSIVersionNumber)</OutputName>
|
||||
<OutputType>Package</OutputType>
|
||||
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' AND '$(MSBuildExtensionsPath32)' != '' ">$(MSBuildExtensionsPath32)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
|
||||
<WixTargetsPath Condition=" '$(WixTargetsPath)' == '' ">$(MSBuildExtensionsPath)\Microsoft\WiX\v3.x\Wix.targets</WixTargetsPath>
|
||||
<Name>TimberWinR.Wix</Name>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<OutputPath>bin\$(Configuration)\</OutputPath>
|
||||
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
|
||||
<DefineConstants>Debug;</DefineConstants>
|
||||
<VerboseOutput>True</VerboseOutput>
|
||||
<WixVariables>
|
||||
</WixVariables>
|
||||
<CompilerAdditionalOptions>
|
||||
</CompilerAdditionalOptions>
|
||||
<LinkerAdditionalOptions>
|
||||
</LinkerAdditionalOptions>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<OutputPath>bin\$(Configuration)\</OutputPath>
|
||||
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Product.wxs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\TimberWinR.ServiceHost\TimberWinR.ServiceHost.csproj">
|
||||
<Name>TimberWinR.ServiceHost</Name>
|
||||
<Project>{2c0b4c56-0d63-4b89-852b-f9bff4431f00}</Project>
|
||||
<Private>True</Private>
|
||||
<DoNotHarvest>True</DoNotHarvest>
|
||||
<RefProjectOutputGroups>Binaries;Content;Satellites</RefProjectOutputGroups>
|
||||
<RefTargetDir>INSTALLFOLDER</RefTargetDir>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(WixTargetsPath)" />
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent />
|
||||
</PropertyGroup>
|
||||
<!--
|
||||
To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Wix.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
Reference in New Issue
Block a user