code: func (t *TerminalHandler) makeClient(ws *websocket.Conn) (*client.TeleportClient, error) {
  	clientConfig, err := makeTeleportClientConfig(t.ctx)
  	if err != nil {
  		return nil, trace.Wrap(err)
  	}
  
  	// Create a terminal stream that wraps/unwraps the envelope used to
  	// communicate over the websocket.
  	stream, err := t.asTerminalStream(ws)
  	if err != nil {
  		return nil, trace.Wrap(err)
  	}
  
  	clientConfig.ForwardAgent = true
  	clientConfig.HostLogin = t.params.Login
  	clientConfig.Namespace = t.params.Namespace
  	clientConfig.Stdout = stream
  	clientConfig.Stderr = stream
  	clientConfig.Stdin = stream
  	clientConfig.SiteName = t.params.Cluster
  	clientConfig.ParseProxyHost(t.params.ProxyHostPort)
  	clientConfig.Host = t.hostName
  	clientConfig.HostPort = t.hostPort
  	clientConfig.Env = map[string]string{sshutils.SessionEnvVar: string(t.params.SessionID)}
  	clientConfig.ClientAddr = ws.Request().RemoteAddr
  
  	if len(t.params.InteractiveCommand) > 0 {
  		clientConfig.Interactive = true
  	}
  
  	tc, err := client.NewClient(clientConfig)
  	if err != nil {
  		return nil, trace.BadParameter("failed to create client: %v", err)
  	}
  
  	// Save the *ssh.Session after the shell has been created. The session is
  	// used to update all other parties window size to that of the web client and
  	// to allow future window changes.
  	tc.OnShellCreated = func(s *ssh.Session, c *ssh.Client, _ io.ReadWriteCloser) (bool, error) {
  		t.sshSession = s
  		t.windowChange(&t.params.Term)
  		return false, nil
  	}
  
  	return tc, nil
  }
docs: // makeClient builds a *client.TeleportClient for the connection.