diff --git a/.github/workflows/build_packages.yaml b/.github/workflows/build_packages.yaml index be6c73068..80a87662a 100644 --- a/.github/workflows/build_packages.yaml +++ b/.github/workflows/build_packages.yaml @@ -102,9 +102,16 @@ jobs: - name: run emqx timeout-minutes: 5 run: | + $ErrorActionPreference = "Stop" ./_build/${{ matrix.profile }}/rel/emqx/bin/emqx start - Start-Sleep -s 5 - echo "EMQX started" + Start-Sleep -s 10 + $pingOutput = ./_build/${{ matrix.profile }}/rel/emqx/bin/emqx ping + if ($pingOutput = 'pong') { + echo "EMQX started OK" + } else { + echo "Failed to ping EMQX $pingOutput" + Exit 1 + } ./_build/${{ matrix.profile }}/rel/emqx/bin/emqx stop echo "EMQX stopped" ./_build/${{ matrix.profile }}/rel/emqx/bin/emqx install diff --git a/bin/emqx.cmd b/bin/emqx.cmd index ede51a56b..2871bcc20 100644 --- a/bin/emqx.cmd +++ b/bin/emqx.cmd @@ -46,6 +46,7 @@ @set "RUNNER_ROOT_DIR=%rel_root_dir%" :: hard code etc dir @set "EMQX_ETC_DIR=%rel_root_dir%\etc" +@set "EMQX_LOG_DIR=%rel_root_dir%\log" @set "etc_dir=%rel_root_dir%\etc" @set "lib_dir=%rel_root_dir%\lib" @set "emqx_conf=%etc_dir%\emqx.conf" diff --git a/changes/ce/fix-10785.en.md b/changes/ce/fix-10785.en.md new file mode 100644 index 000000000..14075593f --- /dev/null +++ b/changes/ce/fix-10785.en.md @@ -0,0 +1,3 @@ +Ensure `EMQX_LOG_DIR` is set by Windows boot script. + +The environment variable `EMQX_LOG_DIR` was missing in v5.0.25, caused EMQX Windows package fail to boot unless set by sysadmin.