FastPath installer doesn't work on Linux
What happened?
I've ran the install steps in the Fast Path Install guide and it's giving a sh: 64: [[: not found.
Suggestion: change the install command to:
curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | bash
Version
n/a
Affects Versions
No response
@vcampitelli can you provide additional detail?
- What version of Linux are you using?
- What shell are you using?
What happens if you run the command as documented here https://fusionauth.io/docs/get-started/download-and-install/fast-path instead of modifying it?
sh -c "curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | sh -s - -z"
It looks like you are running a different version of the command - if that is the case it is not supported. Please re-open if running the command as documented does not work.
Hi @robotdan,
I'm running the exact command from the docs (sh -c "curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | sh").
My suggestion is to change sh to bash, as the [[ ]] syntax for ifs aren't supported by dash, which is the default shell implementation on the majority of Linux distributions out there.
@vcampitelli can you please add the other information @robotdan requested?
- What version of Linux are you using? Ubuntu 23.10
- What shell are you using? Default shell from distro (dash)
There are a lot of distros that use dash by default, like Debian and Ubuntu:
$ docker run --rm -it debian:12 sh -c 'apt-get -qq update && apt-get -qqy install curl unzip > /dev/null && sh -c "curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | sh"'
$ docker run --rm -it ubuntu:23.10 sh -c 'apt-get -qq update && apt-get -qqy install curl unzip > /dev/null && sh -c "curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | sh"'
These errors are related to using [[ and ]], which aren't supported by Dash.
It does work on alpine and arch, because they use bash and busybox as the default shell interpreter, respectively:
Changing the command to use bash instead of sh will work in almost all Linux distros (the only one I know that doesn't have bash by default is alpine, which is normally used within containers and not in the userland).