1diff --git a/shells/bash.go b/shells/bash.go
2index 839b7781..2b478e1e 100644
3--- a/shells/bash.go
4+++ b/shells/bash.go
5@@ -7,6 +7,7 @@ import (
6 "gitlab.com/gitlab-org/gitlab-ci-multi-runner/common"
7 "gitlab.com/gitlab-org/gitlab-ci-multi-runner/helpers"
8 "io"
9+ "os/exec"
10 "path"
11 "runtime"
12 "strconv"
13@@ -208,7 +209,11 @@ func (b *BashShell) GetConfiguration(info common.ShellScriptInfo) (script *commo
14 if info.User != "" {
15 script.Command = "su"
16 if runtime.GOOS == "linux" {
17- script.Arguments = append(script.Arguments, "-s", "/bin/"+b.Shell)
18+ shellPath, err := exec.LookPath(b.Shell)
19+ if err != nil {
20+ shellPath = "/bin/"+b.Shell
21+ }
22+ script.Arguments = append(script.Arguments, "-s", shellPath)
23 }
24 script.Arguments = append(script.Arguments, info.User)
25 script.Arguments = append(script.Arguments, "-c", shellCommand)