-
Notifications
You must be signed in to change notification settings - Fork 165
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Windows MSI to the release (#560)
* Add Windows MSI to the release * Add MSI support to generate-goreleaser * Setup wixl * Remove InstallPrivileges and InstallScope from wxs * Remove RemoveFile element * Directory is not supported on CustomAction * Remove path prefix from opentelemetry.ico * Path to opentelemetry.ico * Use sys.SOURCEFILEDIR to locate .ico file * Use sys.CURRENTDIR to locate ico file * Remove path not present on GH execution * Try to locate opentelmetry.ico * Fix location of ico file when building MSI * CURRENTDIR since SOURCEFILEDIR gives the wxs file * Remove GH action step to locate ico file * Temporarily duplicate windows folder for otelcol-contrib distribution * Temporary action to upload artifacts * Register event source for the collector * Use distribution name as service name * Better provider name to show up on the event viewer * Match both installer.wxs * Add COLLECTOR_SVC_ARGS property * Use ubuntu 22.04 in order to get latest wixl It has proper support for CustomAction. * CURRENTDIR didn't work with wixl 101 SOURCEFILEDIR didn'1 work with wixl 100 ... * Change the location of opentelemetry.ico * Move wxs source * Use the binary name as event provider name * Remove temporary action to upload artifacts
- Loading branch information
Showing
13 changed files
with
227 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> | ||
<Product | ||
Name="OpenTelemetry Collector ({{ .Version }}) - {{ .Binary }} distribution" | ||
Id="B250A214-D463-4E9B-8902-1DE5C19EA951" | ||
UpgradeCode="B7C263DD-95A5-436A-A025-DCA5200C2BE3" | ||
Version="{{ .Version }}" | ||
Manufacturer="OpenTelemetry" | ||
Language="1033"> | ||
|
||
<Package | ||
InstallerVersion="200" | ||
Compressed="yes" | ||
Comments="Windows Installer Package" | ||
InstallScope="perMachine"/> | ||
<Media Id="1" Cabinet="product.cab" EmbedCab="yes"/> | ||
<Icon Id="ProductIcon" SourceFile="opentelemetry.ico"/> | ||
<Property Id="ARPPRODUCTICON" Value="ProductIcon"/> | ||
<Property Id="ARPHELPLINK" Value="https://opentelemetry.io/"/> | ||
<Property Id="ARPURLINFOABOUT" Value="https://opentelemetry.io/"/> | ||
<Property Id="ARPNOREPAIR" Value="1"/> | ||
<Property Id="ARPNOMODIFY" Value="1"/> | ||
|
||
<MajorUpgrade | ||
DowngradeErrorMessage="A later version of OpenTelemetry Collector already installed. Setup will now exit."/> | ||
|
||
<Feature Id="Feature" Level="1"> | ||
<ComponentRef Id="ApplicationComponent"/> | ||
</Feature> | ||
|
||
<Property Id="COLLECTOR_SVC_ARGS"/> | ||
<CustomAction | ||
Id="SetCollectorSvcArgs" | ||
Property="COLLECTOR_SVC_ARGS" | ||
Value="--config "[INSTALLDIR]config.yaml""/> | ||
|
||
<InstallExecuteSequence> | ||
<Custom Action="SetCollectorSvcArgs" Before="InstallFiles">NOT COLLECTOR_SVC_ARGS</Custom> | ||
</InstallExecuteSequence> | ||
|
||
<Directory Id="TARGETDIR" Name="SourceDir"> | ||
<Directory Id="ProgramFiles64Folder"> | ||
<Directory Id="INSTALLDIR" Name="OpenTelemetry Collector"> | ||
<Component Id="ApplicationComponent" Guid="1207C3C4-1830-4DC8-8A7B-2BD7DBE45BC3"> | ||
<!-- Files to include --> | ||
<File | ||
Id="{{ .Binary }}.exe" | ||
Name="{{ .Binary }}.exe" | ||
Source="{{ .Binary }}.exe" | ||
KeyPath="yes"/> | ||
<File | ||
Id="config.yaml" | ||
Name="config.yaml" | ||
Source="config.yaml"/> | ||
|
||
<ServiceInstall | ||
Id="Sevice" | ||
Name="{{ .Binary }}" | ||
DisplayName="OpenTelemetry Collector" | ||
Description="Collects, processes, and exports telemetry from various configurable sources." | ||
Type="ownProcess" | ||
Vital="yes" | ||
Start="auto" | ||
Account="LocalSystem" | ||
ErrorControl="normal" | ||
Arguments="[COLLECTOR_SVC_ARGS]" | ||
Interactive="no"/> | ||
<ServiceControl | ||
Id="StartStopRemoveService" | ||
Name="{{ .Binary }}" | ||
Start="install" | ||
Stop="both" | ||
Remove="uninstall" | ||
Wait="yes"/> | ||
|
||
<RegistryKey | ||
Root="HKLM" | ||
Key="SYSTEM\CurrentControlSet\Services\EventLog\Application\{{ .Binary }}"> | ||
<RegistryValue | ||
Type="expandable" | ||
Name="EventMessageFile" | ||
Value="%SystemRoot%\System32\EventCreate.exe"/> | ||
</RegistryKey> | ||
</Component> | ||
</Directory> | ||
</Directory> | ||
</Directory> | ||
</Product> | ||
</Wix> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> | ||
<Product | ||
Name="OpenTelemetry Collector ({{ .Version }}) - {{ .Binary }} distribution" | ||
Id="B250A214-D463-4E9B-8902-1DE5C19EA951" | ||
UpgradeCode="B7C263DD-95A5-436A-A025-DCA5200C2BE3" | ||
Version="{{ .Version }}" | ||
Manufacturer="OpenTelemetry" | ||
Language="1033"> | ||
|
||
<Package | ||
InstallerVersion="200" | ||
Compressed="yes" | ||
Comments="Windows Installer Package" | ||
InstallScope="perMachine"/> | ||
<Media Id="1" Cabinet="product.cab" EmbedCab="yes"/> | ||
<Icon Id="ProductIcon" SourceFile="opentelemetry.ico"/> | ||
<Property Id="ARPPRODUCTICON" Value="ProductIcon"/> | ||
<Property Id="ARPHELPLINK" Value="https://opentelemetry.io/"/> | ||
<Property Id="ARPURLINFOABOUT" Value="https://opentelemetry.io/"/> | ||
<Property Id="ARPNOREPAIR" Value="1"/> | ||
<Property Id="ARPNOMODIFY" Value="1"/> | ||
|
||
<MajorUpgrade | ||
DowngradeErrorMessage="A later version of OpenTelemetry Collector already installed. Setup will now exit."/> | ||
|
||
<Feature Id="Feature" Level="1"> | ||
<ComponentRef Id="ApplicationComponent"/> | ||
</Feature> | ||
|
||
<Property Id="COLLECTOR_SVC_ARGS"/> | ||
<CustomAction | ||
Id="SetCollectorSvcArgs" | ||
Property="COLLECTOR_SVC_ARGS" | ||
Value="--config "[INSTALLDIR]config.yaml""/> | ||
|
||
<InstallExecuteSequence> | ||
<Custom Action="SetCollectorSvcArgs" Before="InstallFiles">NOT COLLECTOR_SVC_ARGS</Custom> | ||
</InstallExecuteSequence> | ||
|
||
<Directory Id="TARGETDIR" Name="SourceDir"> | ||
<Directory Id="ProgramFiles64Folder"> | ||
<Directory Id="INSTALLDIR" Name="OpenTelemetry Collector"> | ||
<Component Id="ApplicationComponent" Guid="1207C3C4-1830-4DC8-8A7B-2BD7DBE45BC3"> | ||
<!-- Files to include --> | ||
<File | ||
Id="{{ .Binary }}.exe" | ||
Name="{{ .Binary }}.exe" | ||
Source="{{ .Binary }}.exe" | ||
KeyPath="yes"/> | ||
<File | ||
Id="config.yaml" | ||
Name="config.yaml" | ||
Source="config.yaml"/> | ||
|
||
<ServiceInstall | ||
Id="Sevice" | ||
Name="{{ .Binary }}" | ||
DisplayName="OpenTelemetry Collector" | ||
Description="Collects, processes, and exports telemetry from various configurable sources." | ||
Type="ownProcess" | ||
Vital="yes" | ||
Start="auto" | ||
Account="LocalSystem" | ||
ErrorControl="normal" | ||
Arguments="[COLLECTOR_SVC_ARGS]" | ||
Interactive="no"/> | ||
<ServiceControl | ||
Id="StartStopRemoveService" | ||
Name="{{ .Binary }}" | ||
Start="install" | ||
Stop="both" | ||
Remove="uninstall" | ||
Wait="yes"/> | ||
|
||
<RegistryKey | ||
Root="HKLM" | ||
Key="SYSTEM\CurrentControlSet\Services\EventLog\Application\{{ .Binary }}"> | ||
<RegistryValue | ||
Type="expandable" | ||
Name="EventMessageFile" | ||
Value="%SystemRoot%\System32\EventCreate.exe"/> | ||
</RegistryKey> | ||
</Component> | ||
</Directory> | ||
</Directory> | ||
</Directory> | ||
</Product> | ||
</Wix> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters