mirror of
https://github.com/Kiritow/wg-ops.git
synced 2024-03-22 13:11:37 +08:00
Finished W2U LoadBalancer
This commit is contained in:
parent
b87f956b25
commit
e77afc3264
|
@ -2,7 +2,7 @@
|
||||||
set -xe
|
set -xe
|
||||||
|
|
||||||
sudo apt update
|
sudo apt update
|
||||||
sudo apt install -y curl wireguard python3 tmux
|
sudo apt install -y curl wireguard python3 tmux build-essential
|
||||||
|
|
||||||
mkdir -p local
|
mkdir -p local
|
||||||
mkdir -p local/tunnel
|
mkdir -p local/tunnel
|
||||||
|
@ -10,6 +10,8 @@ mkdir -p local/tunnel
|
||||||
mkdir -p bin
|
mkdir -p bin
|
||||||
cd bin
|
cd bin
|
||||||
|
|
||||||
|
gcc -O3 -o w2u ../w2u.c
|
||||||
|
|
||||||
curl -vL https://github.com/wangyu-/udp2raw-tunnel/releases/download/20200818.0/udp2raw_binaries.tar.gz -o udp2raw.tgz
|
curl -vL https://github.com/wangyu-/udp2raw-tunnel/releases/download/20200818.0/udp2raw_binaries.tar.gz -o udp2raw.tgz
|
||||||
tar -xvzf udp2raw.tgz udp2raw_amd64
|
tar -xvzf udp2raw.tgz udp2raw_amd64
|
||||||
chmod +x udp2raw_amd64
|
chmod +x udp2raw_amd64
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
set -xe
|
set -xe
|
||||||
|
|
||||||
sudo apt update
|
sudo apt update
|
||||||
sudo apt install -y curl wireguard python3 tmux
|
sudo apt install -y curl wireguard python3 tmux build-essential
|
||||||
|
|
||||||
mkdir -p local
|
mkdir -p local
|
||||||
mkdir -p local/tunnel
|
mkdir -p local/tunnel
|
||||||
|
@ -10,6 +10,8 @@ mkdir -p local/tunnel
|
||||||
mkdir -p bin
|
mkdir -p bin
|
||||||
cd bin
|
cd bin
|
||||||
|
|
||||||
|
gcc -O3 -o w2u ../w2u.c
|
||||||
|
|
||||||
rm -rf wg-op-binary
|
rm -rf wg-op-binary
|
||||||
git clone https://gitee.com/kiritow/wg-op-binary
|
git clone https://gitee.com/kiritow/wg-op-binary
|
||||||
cd wg-op-binary
|
cd wg-op-binary
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import os
|
import os
|
||||||
import getpass
|
import getpass
|
||||||
from tool_common import load_config, save_config, SimpleLogger, json_to_base64
|
from tool_common import load_config, save_config, json_to_base64
|
||||||
|
|
||||||
|
|
||||||
config = load_config()
|
config = load_config()
|
||||||
|
|
|
@ -16,6 +16,7 @@ def write_tunnel_config(mode, listen_addr, remote_addr, password):
|
||||||
-r {}
|
-r {}
|
||||||
-k {}
|
-k {}
|
||||||
--raw-mode faketcp
|
--raw-mode faketcp
|
||||||
|
--fix-gro
|
||||||
-a
|
-a
|
||||||
'''.format(mode, listen_addr, remote_addr, password))
|
'''.format(mode, listen_addr, remote_addr, password))
|
||||||
return filename
|
return filename
|
||||||
|
|
Loading…
Reference in New Issue
Block a user