Skip to content

Commit

Permalink
test windows packaging
Browse files Browse the repository at this point in the history
Signed-off-by: Justin Kolberg <[email protected]>
  • Loading branch information
amdprophet committed Oct 2, 2023
1 parent 9eda0c1 commit 83288d2
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 7 deletions.
25 changes: 19 additions & 6 deletions .github/workflows/dev_builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,19 @@ jobs:
runs-on: windows-2019
needs:
- build
strategy:
matrix:
include:
- arch_os: windows_amd64
platform: x64
fips: false
- arch_os: windows_amd64
platform: x64
fips: true
with:
arch_os: ${{ matrix.arch_os }}
platform: ${{ matrix.platform }}
fips: ${{ matrix.fips }}
steps:
- uses: actions/checkout@v4

Expand All @@ -235,7 +248,7 @@ jobs:
- name: Fetch binary artifact for windows/amd64
uses: actions/download-artifact@v3
with:
name: otelcol-sumo-windows_amd64.exe
name: otelcol-sumo-${{ arch_os }}.exe
path: ./otelcolbuilder/cmd

- name: Set OVERRIDE_BUILD_NUMBER
Expand All @@ -244,15 +257,15 @@ jobs:
- name: Set PRODUCT_VERSION
run: echo "PRODUCT_VERSION=$(./ci/get_version.sh productversion)" >> $GITHUB_ENV

- name: Build MSI for windows/amd64
- name: Build MSI for ${{ arch_os }}
working-directory: ./packaging/msi/wix
run: msbuild.exe -p:Configuration=Release -p:Platform=x64 -p:ProductVersion=$PRODUCT_VERSION -Restore
run: msbuild.exe -p:Configuration=Release -p:Platform=${{ platform }} -p:ProductVersion=$PRODUCT_VERSION -p:FIPSEnabled=${{ fips }} -Restore

- name: Store MSI as action artifact for windows/amd64
- name: Store MSI as action artifact for ${{ arch_os }}
uses: actions/upload-artifact@v3
with:
name: windows_amd64_msi
path: ./packaging/msi/wix/bin/x64/en-US/*.msi
name: ${{ platform }}_msi
path: ./packaging/msi/wix/bin/${{ platform }}/en-US/*.msi
if-no-files-found: error

# Triggers build_packages workflow in the sumologic-otel-collector-packaging
Expand Down
10 changes: 9 additions & 1 deletion packaging/msi/wix/otelcol-sumo.wixproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,26 @@
<Cultures>en-US</Cultures>
<DebugType>none</DebugType>
<RepoRoot>$([System.IO.Path]::GetFullPath('..\..\..'))</RepoRoot>
<FIPSEnabled>false</FIPSEnabled>
</PropertyGroup>

<PropertyGroup>
<SuppressIces>ICE61</SuppressIces>
</PropertyGroup>

<PropertyGroup>
<OutputName>otelcol-sumo_$(ProductVersion)_en-US.$(Platform)</OutputName>
<OutputPath>bin\$(Platform)\</OutputPath>
<IntermediateOutputPath>obj\$(Platform)\</IntermediateOutputPath>
</PropertyGroup>

<PropertyGroup Condition="'$(FIPSEnabled)' == 'false'">
<OutputName>otelcol-sumo_$(ProductVersion)_en-US.$(Platform)</OutputName>
</PropertyGroup>

<PropertyGroup Condition="'$(FIPSEnabled)' == 'true'">
<OutputName>otelcol-sumo_$(ProductVersion)_en-US.$(Platform)-fips</OutputName>
</PropertyGroup>

<PropertyGroup>
<DefineConstants>$(DefineConstants);ProductVersion=$(ProductVersion)</DefineConstants>
<DefineConstants>$(DefineConstants);UpgradeCode=$(UpgradeCode)</DefineConstants>
Expand Down

0 comments on commit 83288d2

Please sign in to comment.