mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-02 00:10:45 +02:00
test environment ssh config
This commit is contained in:
parent
8d05d3d4b8
commit
0e56f12b83
3 changed files with 54 additions and 26 deletions
|
@ -5,6 +5,7 @@ import (
|
|||
"fmt"
|
||||
"log"
|
||||
"net"
|
||||
"strings"
|
||||
|
||||
"github.com/pomerium/pomerium/internal/testenv"
|
||||
"github.com/pomerium/pomerium/internal/testenv/values"
|
||||
|
@ -201,7 +202,7 @@ func (h *sshUpstream) handleConnection(ctx context.Context, conn net.Conn) {
|
|||
|
||||
// Dial implements SSHUpstream.
|
||||
func (h *sshUpstream) Dial(r testenv.Route, config *ssh.ClientConfig) (*ssh.Client, error) {
|
||||
return ssh.Dial("tcp", h.Env().Config().Options.SSHAddr, config)
|
||||
return ssh.Dial("tcp", strings.TrimPrefix(r.URL().Value(), "ssh://"), config)
|
||||
}
|
||||
|
||||
// DirectDial implements SSHUpstream.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue