Why won't my StackScript run on Alpine Linux?
Linode
Linode Staff
I'm trying to use a StackScript to deploy a Linode running Alpine Linux, and I'm receiving the following error:
can't execute '/root/StackScript': No such file or directory
When I check /root/
, there is a file sitting there called StackScript
. Why isn't this working?
1 Reply
tommydavidson
Linode Staff
Alpine Linux does not have bash
installed by default. This means that any StackScript that begins with #!/bin/bash
will fail to execute. Most StackScripts are written to use bash
, so if your script begins with #!/bin/bash
, you'll need to change it to use something that's natively supported on Alpine, like #!/bin/ash
. I'm admittedly less familiar with ash
and its commands/syntax, but you may need to make some updates to your script to account for the different interpreter.