Verify in ExecStartPre if bash binary exists

Solution 1:

Rather than calling bash, you should consider calling the Bourne shell /bin/sh which has been around pretty much since the beginning of Unix and exists on literally everything Unix-like, all the way down to your phone. (Though on modern systems it is generally substituted with a slightly more capable shell that runs in Bourne shell compatibility mode when called as /bin/sh.)