Title
#fleet
zwass

zwass

07/08/2021, 7:18 PM
@jordi @Jaylen let's continue this discussion in this thread
7:18 PM
With 4.0.0 we did make some changes to the structure and naming of the release archives. The NPM fleetctl package should handle this, but there may be some remaining bugs.
7:19 PM
One thing I am unclear about is that the
Installing fleetctl 4.0.1...
message comes from the NPM package, while the message above states that
fleetctl
was downloaded in binary form. Can you provide the exact commands that you ran and the output so that we can try to understand what may be going on?
jordi

jordi

07/08/2021, 7:30 PM
# Install the Fleet command-line tool
sudo npm install -g fleetctl
# Run a local demo of the Fleet server
sudo fleetctl preview
7:30 PM
the ones in the github readme
m

Mike

07/08/2021, 7:59 PM
I just hit this one too on macOS, it's trying to download:
<https://github.com/fleetdm/fleet/releases/download/4.0.1/fleetctl_4.0.1_macos.tar.gz>
but it's
<https://github.com/fleetdm/fleet/releases/download/v4.0.1/fleetctl_v4.0.1_macos.tar.gz>
on GitHub
zwass

zwass

07/08/2021, 8:00 PM
Are you saying that you get this error when you run that command?
m

Mike

07/08/2021, 8:02 PM
sudo fleetctl preview       

Installing fleetctl 4.0.1...
Failed to install: download archive <https://github.com/fleetdm/fleet/releases/download/4.0.1/fleetctl_4.0.1_macos.tar.gz>: Request failed with status code 404
zwass

zwass

07/08/2021, 8:03 PM
What is your
npm --version
?
8:03 PM
docker run --rm -it node bash
root@ac6ea2b3c3b5:/# npm install -g fleetctl

added 22 packages, and audited 23 packages in 1s

3 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
npm notice
npm notice New minor version of npm available! 7.18.1 -> 7.19.1
npm notice Changelog: <https://github.com/npm/cli/releases/tag/v7.19.1>
npm notice Run npm install -g npm@7.19.1 to update!
npm notice
root@ac6ea2b3c3b5:/# fleetctl --version
Installing fleetctl v4.0.1...
Install completed.
fleetctl - version 4.0.1
  branch: 	HEAD
  revision: 	fed68fcb62b1fc79f2edc03056e28b5122a8ae2b
  build date: 	2021-07-01
  build user: 	runner
  go version: 	go1.16.5
8:04 PM
That's in a Docker container. On my mac I get this:
~  npm install -g fleetctl

changed 22 packages, and audited 23 packages in 1s

3 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
 ~  fleetctl --version
Installing fleetctl v4.0.1...
Install completed.
fleetctl - version 4.0.1
  branch: 	HEAD
  revision: 	fed68fcb62b1fc79f2edc03056e28b5122a8ae2b
  build date: 	2021-07-01
  build user: 	runner
  go version: 	go1.16.5
8:05 PM
I am wondering if
npm
might be stripping off the
v
prefix in some versions of
npm
m

Mike

07/08/2021, 8:05 PM
npm is at
6.12.0
on my mac... I'll give it an update
zwass

zwass

07/08/2021, 8:06 PM
Please let us know if that fixes it -- We can add a workaround as well as we'd like to support any reasonable version of
npm
. I'm on 7.6.3 where it works.
m

Mike

07/08/2021, 8:13 PM
That was it! Note you've got to install fleetctl again
sudo npm install -g fleetctl
before trying to run the preview - thanks for the help @zwass!
jordi

jordi

07/08/2021, 8:26 PM
same here I updated npm
6.14.13 → 7.19.1
and now it is working properly
zwass

zwass

07/08/2021, 9:17 PM
Okay thank you both for the input! I've tracked an issue to resolve this: https://github.com/fleetdm/fleet/issues/1335
j

Jaylen

07/09/2021, 3:17 AM
Do we need npm for a binary based installation also ?
5:29 AM
Is there any alternative way to install fleet other than docker
j

Jason

07/09/2021, 3:20 PM
you can install the binary on a VM
zwass

zwass

07/09/2021, 3:35 PM
To be clear,
fleetctl
(available via NPM, binary, or container) is the CLI client for the Fleet server. If you want to install Fleet, you'll need the Fleet server binary or container. Fleet server binaries are available at https://github.com/fleetdm/fleet/releases/tag/v4.0.1.
j

Jaylen

07/10/2021, 6:51 AM
Okay thanks