mirror of
https://github.com/netdata/netdata.git
synced 2025-04-06 22:38:55 +00:00
Address installer minor issues (Windows) (#19122)
* fix_msis2: remove unused file * fix_msis2: Create empty directories ignored by WIX * fix_msis2: Add nano as default editor * fix_msis2: Add missing reference
This commit is contained in:
parent
9e6f454336
commit
dcbcf71743
3 changed files with 41 additions and 43 deletions
packaging
|
@ -1,43 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
repo_root="$(dirname "$(dirname "$(cd "$(dirname "${BASH_SOURCE[0]}")" > /dev/null && pwd -P)")")"
|
||||
|
||||
if [ -n "${BUILD_DIR}" ]; then
|
||||
build="${BUILD_DIR}"
|
||||
elif [ -n "${OSTYPE}" ]; then
|
||||
if [ -n "${MSYSTEM}" ]; then
|
||||
build="${repo_root}/build-${OSTYPE}-${MSYSTEM}"
|
||||
else
|
||||
build="${repo_root}/build-${OSTYPE}"
|
||||
fi
|
||||
elif [ "$USER" = "vk" ]; then
|
||||
build="${repo_root}/build"
|
||||
else
|
||||
build="${repo_root}/build"
|
||||
fi
|
||||
|
||||
set -exu -o pipefail
|
||||
|
||||
${GITHUB_ACTIONS+echo "::group::Installing"}
|
||||
cmake --install "${build}"
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
||||
|
||||
if [ ! -f "/msys2-installer.exe" ]; then
|
||||
${GITHUB_ACTIONS+echo "::group::Fetching MSYS2 installer"}
|
||||
"${repo_root}/packaging/windows/fetch-msys2-installer.py" /msys2-installer.exe
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
||||
fi
|
||||
|
||||
${GITHUB_ACTIONS+echo "::group::Packaging"}
|
||||
NDVERSION=$"$(grep 'CMAKE_PROJECT_VERSION:STATIC' "${build}/CMakeCache.txt"| cut -d= -f2)"
|
||||
NDMAJORVERSION=$"$(grep 'CMAKE_PROJECT_VERSION_MAJOR:STATIC' "${build}/CMakeCache.txt"| cut -d= -f2)"
|
||||
NDMINORVERSION=$"$(grep 'CMAKE_PROJECT_VERSION_MINOR:STATIC' "${build}/CMakeCache.txt"| cut -d= -f2)"
|
||||
|
||||
if [ -f "/gpl-3.0.txt" ]; then
|
||||
${GITHUB_ACTIONS+echo "::group::Fetching GPL3 License"}
|
||||
curl -o /gpl-3.0.txt "https://www.gnu.org/licenses/gpl-3.0.txt"
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
||||
fi
|
||||
|
||||
/mingw64/bin/makensis.exe -DCURRVERSION="${NDVERSION}" -DMAJORVERSION="${NDMAJORVERSION}" -DMINORVERSION="${NDMINORVERSION}" "${repo_root}/packaging/windows/installer.nsi"
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
|
@ -33,6 +33,11 @@
|
|||
<Feature Id="Main">
|
||||
<ComponentGroupRef Id="NetdataComponents" />
|
||||
<ComponentRef Id="NetdataVarCache" />
|
||||
<ComponentRef Id="NetdataDevShm" />
|
||||
<ComponentRef Id="NetdataDevMqueue" />
|
||||
<ComponentRef Id="NetdataTmp" />
|
||||
<ComponentRef Id="NetdataHome" />
|
||||
<ComponentRef Id="NetdataRoot" />
|
||||
<ComponentRef Id="NetdataVarLib" />
|
||||
<ComponentGroupRef Id="WevtComponents" />
|
||||
<ComponentRef Id="NetdataService" />
|
||||
|
@ -50,6 +55,16 @@
|
|||
<Directory Id="ETCDIR" Name="etc">
|
||||
<Directory Id="ETCDIRNETDATA" Name="netdata" />
|
||||
</Directory>
|
||||
<Directory Id="DEVDIR" Name="dev">
|
||||
<Directory Id="DEVSHMDIR" Name="shm" />
|
||||
<Directory Id="DEVMQUEUEDIR" Name="mqueue" />
|
||||
</Directory>
|
||||
<Directory Id="TMPDIR" Name="tmp">
|
||||
</Directory>
|
||||
<Directory Id="HOMEDIR" Name="home">
|
||||
</Directory>
|
||||
<Directory Id="ROOTDIR" Name="root">
|
||||
</Directory>
|
||||
</Directory>
|
||||
</StandardDirectory>
|
||||
|
||||
|
@ -90,6 +105,26 @@
|
|||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<Component Id="NetdataDevShm" Directory="DEVSHMDIR" Guid="cbe39d53-a5c8-4375-9b25-e24df4d411be">
|
||||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<Component Id="NetdataDevMqueue" Directory="DEVMQUEUEDIR" Guid="f119d45f-b4d4-4918-bf05-89ee88be951a">
|
||||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<Component Id="NetdataTmp" Directory="TMPDIR" Guid="19247d2f-0f9d-4891-a3b0-ffc208d8d878">
|
||||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<Component Id="NetdataHome" Directory="HOMEDIR" Guid="13056229-7734-45ac-a982-572fa99f8e72">
|
||||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<Component Id="NetdataRoot" Directory="ROOTDIR" Guid="5f0b7def-c4e6-417a-a5ae-b6f9c4aff14e">
|
||||
<CreateFolder />
|
||||
</Component>
|
||||
|
||||
<CustomAction Id="ClaimAgent" Directory="USRBINDIR" ExeCommand='[USRBINDIR]NetdataClaim.exe /T "[TOKEN]" /R "[ROOMS]" /U "[URL]" /I [INSECURE] /P "[PROXY]" /F "[INSTALLFOLDER]etc\netdata\claim.conf"' Execute="deferred" Return="ignore" Impersonate="no"/>
|
||||
<InstallExecuteSequence>
|
||||
<Custom Action="ClaimAgent" After="InstallFiles" />
|
||||
|
|
|
@ -42,3 +42,9 @@ tar -xf /msys2-latest.tar.zst -C /opt/netdata/ || exit 1
|
|||
cp -R /opt/netdata/msys64/* /opt/netdata/ || exit 1
|
||||
rm -rf /opt/netdata/msys64/
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
||||
|
||||
${GITHUB_ACTIONS+echo "::group::Configure Editor"}
|
||||
if [ -f /opt/netdata/etc/profile ]; then
|
||||
echo 'EDITOR="/usr/bin/nano.exe"' >> /opt/netdata/etc/profile
|
||||
fi
|
||||
${GITHUB_ACTIONS+echo "::endgroup::"}
|
||||
|
|
Loading…
Add table
Reference in a new issue