elastic / elastic-stack-installers

Windows MSI packages for Elastic stack
Apache License 2.0
8 stars 15 forks source link

Remove trailing slash and store data and logs in subfolders #264

Closed strawgate closed 5 months ago

strawgate commented 5 months ago

Properly handle the fact that MSI Directories always end in a slash. This slash results in the second quote of each path being escaped thus breaking the service binpath.

Fixes: #261 Fixes: #262

Caused by https://github.com/elastic/elastic-stack-installers/commit/6bb7be7c5527fa39d3026d4080e8cbb096e81341 in https://github.com/elastic/elastic-stack-installers/pull/209

strawgate commented 5 months ago

Testing 8.14 snapshot artifact...

strawgate commented 5 months ago

Okay -- tested winlogbeat MSI working via double click and service starts once a config is provided. Also tested that specifying INSTALLDIR correctly changes the installdir and service starts once a config is provided.

rismoney commented 5 months ago

what msi version will this drop in ?

pierrehilbert commented 5 months ago

MSI version is in beta in 8.13

amitkanfer commented 5 months ago

MSI version is in beta in 8.13

Unless @rismoney was referring to the bugfix this issue is about? then it's 8.13.3 i believe

rismoney commented 5 months ago

I don't believe the fix is working. I installed 18.13.3 yesterday, and it had trailing slashes here: "HKLM:\SYSTEM\CurrentControlSet\Services\winlogbeat\Imagepath"

contents of regkey after install:

"C:\Program Files\Elastic\Beats\8.13.3\winlogbeat\winlogbeat.exe"  --path.home "C:\Program Files\Elastic\Beats\8.13.3\winlogbeat\" --path.config "C:\Program Files\Elastic\Beats\8.13.3\winlogbeat\" --path.data "C:\Program Files\Elastic\Beats\8.13.3\winlogbeat\" --path.logs "C:\Program Files\Elastic\Beats\8.13.3\winlogbeat\" -E logging.files.redirect_stderr=true