7 sub ethernet_bridge_to {
10 warn "# reset local IP address";
11 system "ifconfig virtual 172.16.10.$id";
13 warn "# connect to $host";
14 my $ssh = Net::OpenSSH->new( $host,
15 master_opts => [ -w => "$id:$id", -o => 'Tunnel=ethernet' ],
18 foreach my $command ( "ifconfig tap$id up", "brctl addif virtual tap$id" ) {
21 $ssh->system( $command ) or die "$command ", $ssh->error;
24 warn "press enter to close tunnel to $host from $id";