gitlab-runner_1_11: add patch to fetch shells from system path
This commit is contained in:
parent
0cd0581b75
commit
2ab474b4a7
@ -0,0 +1,13 @@
|
|||||||
|
diff --git a/shells/bash.go b/shells/bash.go
|
||||||
|
index c9c8b68..c97dbb5 100644
|
||||||
|
--- a/shells/bash.go
|
||||||
|
+++ b/shells/bash.go
|
||||||
|
@@ -208,7 +208,7 @@ func (b *BashShell) GetConfiguration(info common.ShellScriptInfo) (script *commo
|
||||||
|
if info.User != "" {
|
||||||
|
script.Command = "su"
|
||||||
|
if runtime.GOOS == "linux" {
|
||||||
|
- script.Arguments = append(script.Arguments, "-s", "/bin/"+b.Shell)
|
||||||
|
+ script.Arguments = append(script.Arguments, "-s", "/run/current-system/sw/bin/"+b.Shell)
|
||||||
|
}
|
||||||
|
script.Arguments = append(script.Arguments, info.User)
|
||||||
|
script.Arguments = append(script.Arguments, "-c", shellCommand)
|
@ -32,6 +32,8 @@ buildGoPackage rec {
|
|||||||
sha256 = "1sjvlb5981ykc8hr4kp1ibh9jw2wdjjp9zs2nqs9lpsav4nda5fr";
|
sha256 = "1sjvlb5981ykc8hr4kp1ibh9jw2wdjjp9zs2nqs9lpsav4nda5fr";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
patches = [ ./v1-fix-shell-path.patch ];
|
||||||
|
|
||||||
buildInputs = [ go-bindata ];
|
buildInputs = [ go-bindata ];
|
||||||
|
|
||||||
preBuild = ''
|
preBuild = ''
|
||||||
|
Loading…
x
Reference in New Issue
Block a user