Title
#fleet
r

Rofl

11/18/2022, 9:02 AM
$ fleetctl package --type=pkg --fleet-url=<https://X> --enroll-secret=X
Generating your osquery installer...
Unable to find path: /root/root
Error: build pkg: mkbom: exit status 1
9:03 AM
Same goes for msi:
$ fleetctl package --type=msi --fleet-url=<https://X> --enroll-secret=X
Generating your osquery installer...
Windows Installer XML Toolset Toolset Harvester version 
Copyright (c) .NET Foundation and contributors. All rights reserved.

heat.exe : error HEAT5052 : The directory 'Z:\wix\root' could not be found.
Error: package root files: heat failed: exit status 188
j

Jeremy Blalock

11/18/2022, 2:14 PM
If memory serves me correctly to build the client agent using a different OS than the type you are setting you need to have Docker engine installed. Fleetctl uses Docker to emulate the target OS type as part of the build. I had found some documentation around that at one point, but Google fu is failing me now to find it again.
r

Rofl

11/18/2022, 2:21 PM
I have docker installed
2:21 PM
Linux building works perfectly
2:22 PM
not osx/msi
j

Jeremy Blalock

11/18/2022, 2:23 PM
Got me then. Hopefully someone more knowledgeable else chimes in.
r

Rofl

11/18/2022, 2:23 PM
Thanks
Benjamin Edwards

Benjamin Edwards

11/18/2022, 2:42 PM
can you run
fleetctl --version
? and
docker --version
2:43 PM
āžœ  Downloads docker --version
Docker version 20.10.21, build baeda1f
āžœ  Downloads fleetctl --version
fleetctl - version 4.23.0
  branch: 	HEAD
  revision: 	af0c75e08bc37d1c81f38fd24dfaf0d473d8a499
  build date: 	2022-11-14
  build user: 	runner
  go version: 	go1.19.3
running package yields:
Downloads fleetctl package --type=msi --fleet-desktop --fleet-url=<http://localhost:8080> --enroll-secret=<omitted>
Generating your osquery installer...
Unable to find image 'fleetdm/wix:latest' locally
latest: Pulling from fleetdm/wix
7d63c13d9b9b: Pull complete 
d6b3bca85310: Pull complete 
26a41d401cc6: Pull complete 
1a28001a7315: Pull complete 
86ad66875459: Pull complete 
4f4fb700ef54: Pull complete 
Digest: sha256:3183e1a702efe74cef600b73c193605bed5aeff53f09cf858b86fe66efdd8e3e
Status: Downloaded newer image for fleetdm/wix:latest
Windows Installer XML Toolset Toolset Harvester version 
Copyright (c) .NET Foundation and contributors. All rights reserved.

Windows Installer XML Toolset Compiler version 
Copyright (c) .NET Foundation and contributors. All rights reserved.

heat.wxs
main.wxs
Windows Installer XML Toolset Linker version 
Copyright (c) .NET Foundation and contributors. All rights reserved.


Success! You generated an osquery installer at /home/ben/Downloads/fleet-osquery.msi
2:44 PM
are you on WSL?
zwass

zwass

11/18/2022, 10:49 PM
I think we've seen errors like this when there are issues sharing a volume with the container trying to do the build. If you are on Linux you might need to install a different Docker distribution and/or run with
sudo
for the appropriate permissions.
r

Rofl

11/22/2022, 8:57 AM
sorry for the late reply here:
$ fleetctl --version
fleetctl - version 4.23.0
  branch: 	HEAD
  revision: 	af0c75e08bc37d1c81f38fd24dfaf0d473d8a499
  build date: 	2022-11-14
  build user: 	runner
  go version: 	go1.19.3
8:57 AM
$ docker --version
Docker version 20.10.17, build 100c70180f
8:58 AM
Running as root didnt help either
8:58 AM
This is Ubuntu 22.04 btw
Tiernan

Tiernan

12/02/2022, 10:12 AM
My experience with this is that you need to run the create the MSI using a windows machine & .PKG using a mac. I have VMs setup just for it.