Merge pull request #120740 from ymatsiuk/teleport
teleport: 6.1.2 -> 6.1.3
This commit is contained in:
commit
d5b9c17485
2 changed files with 24 additions and 4 deletions
|
@ -11,14 +11,14 @@ in
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "teleport";
|
||||
version = "6.1.2";
|
||||
version = "6.1.3";
|
||||
|
||||
# This repo has a private submodule "e" which fetchgit cannot handle without failing.
|
||||
src = fetchFromGitHub {
|
||||
owner = "gravitational";
|
||||
repo = "teleport";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-4ZaebTTgGrGRQbMfDw1PL/qtDKmHbSY6kPmWyFeIcAU=";
|
||||
sha256 = "sha256-kb7qRPZKXDY0Qy3/72epAGaN2FCOO/XAN8lOoUYkoM0=";
|
||||
};
|
||||
|
||||
vendorSha256 = null;
|
||||
|
@ -27,6 +27,9 @@ buildGoModule rec {
|
|||
|
||||
nativeBuildInputs = [ zip makeWrapper ];
|
||||
|
||||
# https://github.com/NixOS/nixpkgs/issues/120738
|
||||
patches = [ ./tsh.patch ];
|
||||
|
||||
postBuild = ''
|
||||
pushd .
|
||||
mkdir -p build
|
||||
|
@ -54,8 +57,8 @@ buildGoModule rec {
|
|||
|
||||
postInstall = ''
|
||||
install -Dm755 -t $client/bin $out/bin/tsh
|
||||
wrapProgram $client/bin/tsh --prefix PATH : ${xdg-utils}/bin
|
||||
wrapProgram $out/bin/tsh --prefix PATH : ${xdg-utils}/bin
|
||||
wrapProgram $client/bin/tsh --prefix PATH : ${lib.makeBinPath [ xdg-utils ]}
|
||||
wrapProgram $out/bin/tsh --prefix PATH : ${lib.makeBinPath [ xdg-utils ]}
|
||||
'';
|
||||
|
||||
doInstallCheck = true;
|
||||
|
|
17
pkgs/servers/teleport/tsh.patch
Normal file
17
pkgs/servers/teleport/tsh.patch
Normal file
|
@ -0,0 +1,17 @@
|
|||
diff --git a/tool/tsh/tsh.go b/tool/tsh/tsh.go
|
||||
index 57379c40f..cb4d7b84c 100644
|
||||
--- a/tool/tsh/tsh.go
|
||||
+++ b/tool/tsh/tsh.go
|
||||
@@ -514,10 +514,11 @@ func Run(args []string, opts ...cliOption) error {
|
||||
}
|
||||
}
|
||||
|
||||
- cf.executablePath, err = os.Executable()
|
||||
+ tempBinaryPath, err := os.Executable()
|
||||
if err != nil {
|
||||
return trace.Wrap(err)
|
||||
}
|
||||
+ cf.executablePath = path.Dir(tempBinaryPath) + "/tsh"
|
||||
|
||||
if err := client.ValidateAgentKeyOption(cf.AddKeysToAgent); err != nil {
|
||||
return trace.Wrap(err)
|
Loading…
Reference in a new issue