mirror of
https://github.com/sshuttle/sshuttle.git
synced 2025-08-11 00:31:14 +02:00
!improved windrivert throughput
This commit is contained in:
@ -68,6 +68,13 @@ if [[ $ssh_copy_id == true ]]; then
|
||||
with_set_x ssh-copy-id -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -p "$port" "$user@$host"
|
||||
fi
|
||||
|
||||
sshuttle_bin=${sshuttle_bin:-"$(dirname "$0")/../run"}
|
||||
if [[ -z $sshuttle_bin || "$sshuttle_bin" == dev ]]; then
|
||||
cd "$(dirname "$0")/.."
|
||||
export PYTHONPATH="."
|
||||
sshuttle_bin="./run"
|
||||
fi
|
||||
|
||||
set -x
|
||||
|
||||
exec "${sshuttle_bin}" -r "$user@$host:$port" --ssh-cmd "$ssh_cmd" "${args[@]}"
|
||||
|
||||
|
@ -18,9 +18,6 @@ benchmark() {
|
||||
local sshuttle_bin="${1?:}"
|
||||
local node="${2:-'node-1'}"
|
||||
echo -e "\n======== Benchmarking sshuttle: $sshuttle_bin ========"
|
||||
if [[ "$sshuttle_bin" == dev ]]; then
|
||||
sshuttle_bin="../run"
|
||||
fi
|
||||
./exec-sshuttle "$node" --sshuttle-bin="$sshuttle_bin" --listen 55771 &
|
||||
sshuttle_pid=$!
|
||||
trap 'kill -0 $sshuttle_pid &>/dev/null && kill -15 $sshuttle_pid' EXIT
|
||||
@ -34,6 +31,6 @@ benchmark() {
|
||||
if [[ "$1" ]]; then
|
||||
benchmark "$1"
|
||||
else
|
||||
benchmark "${SSHUTTLE_BIN:-/bin/sshuttle}" node-1
|
||||
benchmark "${SSHUTTLE_BIN:-sshuttle}" node-1
|
||||
benchmark dev node-1
|
||||
fi
|
||||
|
Reference in New Issue
Block a user