mirror of
https://github.com/oneclickvirt/ecs.git
synced 2025-09-28 04:02:12 +08:00
Compare commits
45 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
835dc7a0fd | ||
![]() |
cdfb956211 | ||
![]() |
d5ba31e5d7 | ||
![]() |
e80ec4f063 | ||
![]() |
cdb8d8681e | ||
![]() |
d6d0abeb1c | ||
![]() |
9565248f95 | ||
![]() |
1d6cd5984b | ||
![]() |
63b857c915 | ||
![]() |
6811f19db4 | ||
![]() |
847e1c0d6e | ||
![]() |
99a8448d53 | ||
![]() |
4fe9cd21ef | ||
![]() |
bdb53ac436 | ||
![]() |
01b9ee4505 | ||
![]() |
fadbf9c6aa | ||
![]() |
60e235e4d7 | ||
![]() |
da4b431761 | ||
![]() |
7fff30521e | ||
![]() |
e7c78774ca | ||
![]() |
fb6f9da14c | ||
![]() |
7b1773c5f0 | ||
![]() |
7b15a74448 | ||
![]() |
956f65941e | ||
![]() |
6d1f806e94 | ||
![]() |
d727d6b778 | ||
![]() |
ea891861b3 | ||
![]() |
e0826a80c8 | ||
![]() |
74868a918e | ||
![]() |
889ecee3f3 | ||
![]() |
f6dd0bbb56 | ||
![]() |
01686f3e9d | ||
![]() |
5a6cd7d671 | ||
![]() |
35e183b640 | ||
![]() |
a684052966 | ||
![]() |
2beb74c319 | ||
![]() |
5218c95162 | ||
![]() |
83be2066c8 | ||
![]() |
975bcbfc00 | ||
![]() |
dbddbc29a3 | ||
![]() |
af3894a908 | ||
![]() |
abb2fd079a | ||
![]() |
83dacb4e6b | ||
![]() |
e83cbaf011 | ||
![]() |
ecd61fd51b |
136
README.md
136
README.md
@@ -25,6 +25,140 @@ Shell版本: https://github.com/spiritLHLS/ecs
|
|||||||
|
|
||||||
- [ ] 测试三网Ping值[借鉴[ecsspeed](https://github.com/spiritLHLS/ecsspeed)的逻辑二次开发]
|
- [ ] 测试三网Ping值[借鉴[ecsspeed](https://github.com/spiritLHLS/ecsspeed)的逻辑二次开发]
|
||||||
|
|
||||||
## 说明
|
## Linux/macOS上使用的说明
|
||||||
|
|
||||||
开发中,勿要使用
|
开发中,勿要使用
|
||||||
|
|
||||||
|
下载脚本
|
||||||
|
|
||||||
|
```
|
||||||
|
curl -L https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
或
|
||||||
|
|
||||||
|
```
|
||||||
|
curl -L https://cdn.spiritlhl.net/https://raw.githubusercontent.com/oneclickvirt/ecs/master/goecs.sh -o goecs.sh && chmod +x goecs.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
安装环境
|
||||||
|
|
||||||
|
```
|
||||||
|
./goecs.sh env
|
||||||
|
```
|
||||||
|
|
||||||
|
安装goecs
|
||||||
|
|
||||||
|
```
|
||||||
|
./goecs.sh install
|
||||||
|
```
|
||||||
|
|
||||||
|
升级goecs
|
||||||
|
|
||||||
|
```
|
||||||
|
./goecs.sh upgrade
|
||||||
|
```
|
||||||
|
|
||||||
|
卸载goecs
|
||||||
|
|
||||||
|
```
|
||||||
|
./goecs.sh delete
|
||||||
|
```
|
||||||
|
|
||||||
|
shell脚本的说明
|
||||||
|
|
||||||
|
```
|
||||||
|
Available commands:
|
||||||
|
|
||||||
|
./goecs.sh env Check and Install package:
|
||||||
|
tar (Almost all unix-like systems have it.)
|
||||||
|
unzip (Almost all unix-like systems have it.)
|
||||||
|
dd (Almost all unix-like systems have it.)
|
||||||
|
fio (Almost all unix-like systems can be installed through the system's package manager.)
|
||||||
|
sysbench (Almost all unix-like systems can be installed through the system's package manager.)
|
||||||
|
geekbench (geekbench5)(Only support IPV4 environment, and memory greater than 1GB network detection, only support amd64 and arm64 architecture.)
|
||||||
|
speedtest (Use the officially provided binaries for more accurate test results.)
|
||||||
|
In fact, sysbench/geekbench is the only one of the above dependencies that must be installed, without which the CPU score cannot be tested.
|
||||||
|
./goecs.sh install Install goecs command
|
||||||
|
./goecs.sh upgrade Upgrade goecs command
|
||||||
|
./goecs.sh delete Uninstall goecs command
|
||||||
|
./goecs.sh help Show this message
|
||||||
|
```
|
||||||
|
|
||||||
|
goecs唤起菜单
|
||||||
|
|
||||||
|
```
|
||||||
|
goecs
|
||||||
|
```
|
||||||
|
|
||||||
|
或
|
||||||
|
|
||||||
|
```
|
||||||
|
./goecs
|
||||||
|
```
|
||||||
|
|
||||||
|
goecs命令参数化
|
||||||
|
|
||||||
|
```
|
||||||
|
Usage: goecs [options]
|
||||||
|
-backtrace
|
||||||
|
Enable/Disable backtrace test (in 'en' language or on windows it always false) (default true)
|
||||||
|
-basic
|
||||||
|
Enable/Disable basic test (default true)
|
||||||
|
-comm
|
||||||
|
Enable/Disable common media test (default true)
|
||||||
|
-cpu
|
||||||
|
Enable/Disable CPU test (default true)
|
||||||
|
-cpum string
|
||||||
|
Set CPU test method (supported: sysbench, geekbench, winsat) (default "sysbench")
|
||||||
|
-cput string
|
||||||
|
Set CPU test thread mode (supported: single, multi) (default "multi")
|
||||||
|
-disk
|
||||||
|
Enable/Disable disk test (default true)
|
||||||
|
-diskm string
|
||||||
|
Set disk test method (supported: fio, dd, winsat) (default "fio")
|
||||||
|
-diskmc
|
||||||
|
Enable/Disable multiple disk checks, e.g., -diskmc=false
|
||||||
|
-diskp string
|
||||||
|
Set disk test path, e.g., -diskp /root
|
||||||
|
-email
|
||||||
|
Enable/Disable email port test (default true)
|
||||||
|
-h Show help information
|
||||||
|
-l string
|
||||||
|
Set language (supported: en, zh) (default "zh")
|
||||||
|
-log
|
||||||
|
Enable/Disable logging in the current path
|
||||||
|
-memory
|
||||||
|
Enable/Disable memory test (default true)
|
||||||
|
-memorym string
|
||||||
|
Set memory test method (supported: sysbench, dd, winsat) (default "dd")
|
||||||
|
-menu
|
||||||
|
Enable/Disable menu mode, disable example: -menu=false (default true)
|
||||||
|
-nt3
|
||||||
|
Enable/Disable NT3 test (in 'en' language or on windows it always false) (default true)
|
||||||
|
-nt3loc string
|
||||||
|
Specify NT3 test location (supported: GZ, SH, BJ, CD for Guangzhou, Shanghai, Beijing, Chengdu) (default "GZ")
|
||||||
|
-nt3t string
|
||||||
|
Set NT3 test type (supported: both, ipv4, ipv6) (default "ipv4")
|
||||||
|
-security
|
||||||
|
Enable/Disable security test (default true)
|
||||||
|
-speed
|
||||||
|
Enable/Disable speed test (default true)
|
||||||
|
-spnum int
|
||||||
|
Set the number of servers per operator for speed test (default 2)
|
||||||
|
-ut
|
||||||
|
Enable/Disable unlock media test (default true)
|
||||||
|
-v Display version information
|
||||||
|
```
|
||||||
|
|
||||||
|
## Windows上使用的说明
|
||||||
|
|
||||||
|
下载带exe文件的压缩文件
|
||||||
|
|
||||||
|
https://github.com/oneclickvirt/ecs/releases
|
||||||
|
|
||||||
|
找其中最新的版本,按照对应架构下载对应的 .tar.gz 文件,解压后文件夹内有一个exe文件
|
||||||
|
|
||||||
|
选择该exe文件,右键点击选择管理员模式运行(非管理员模式运行无法进行硬件测试),唤起菜单自选
|
||||||
|
|
||||||
|
windows测试无需进行环境安装
|
44
go.mod
44
go.mod
@@ -3,17 +3,19 @@ module github.com/oneclickvirt/ecs
|
|||||||
go 1.22.4
|
go 1.22.4
|
||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/oneclickvirt/CommonMediaTests v0.0.2-20240630023003
|
github.com/imroc/req/v3 v3.43.7
|
||||||
|
github.com/oneclickvirt/CommonMediaTests v0.0.3-20240702073302
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930
|
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930
|
||||||
github.com/oneclickvirt/backtrace v0.0.4-20240624090335
|
github.com/oneclickvirt/backtrace v0.0.4-20240624090335
|
||||||
github.com/oneclickvirt/basics v0.0.3-20240625075226
|
github.com/oneclickvirt/basics v0.0.5-20240702055351
|
||||||
github.com/oneclickvirt/cputest v0.0.5-20240630022206
|
github.com/oneclickvirt/cputest v0.0.8-20240702070215
|
||||||
github.com/oneclickvirt/defaultset v0.0.2-20240624082446
|
github.com/oneclickvirt/defaultset v0.0.2-20240624082446
|
||||||
github.com/oneclickvirt/disktest v0.0.3-20240629152513
|
github.com/oneclickvirt/disktest v0.0.4-20240702071738
|
||||||
github.com/oneclickvirt/memorytest v0.0.1-20240624151629
|
github.com/oneclickvirt/gostun v0.0.3-20240702054621
|
||||||
github.com/oneclickvirt/nt3 v0.0.1-20240627070009
|
github.com/oneclickvirt/memorytest v0.0.2-20240702031042
|
||||||
|
github.com/oneclickvirt/nt3 v0.0.2-20240630152642
|
||||||
github.com/oneclickvirt/portchecker v0.0.1-20240624155429
|
github.com/oneclickvirt/portchecker v0.0.1-20240624155429
|
||||||
github.com/oneclickvirt/security v0.0.1-20240630101628
|
github.com/oneclickvirt/security v0.0.4-20240702055848
|
||||||
github.com/oneclickvirt/speedtest v0.0.6-20240630114816
|
github.com/oneclickvirt/speedtest v0.0.6-20240630114816
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -21,24 +23,21 @@ require (
|
|||||||
github.com/PuerkitoBio/goquery v1.9.2 // indirect
|
github.com/PuerkitoBio/goquery v1.9.2 // indirect
|
||||||
github.com/andybalholm/brotli v1.1.0 // indirect
|
github.com/andybalholm/brotli v1.1.0 // indirect
|
||||||
github.com/andybalholm/cascadia v1.3.2 // indirect
|
github.com/andybalholm/cascadia v1.3.2 // indirect
|
||||||
github.com/cloudflare/circl v1.3.7 // indirect
|
github.com/cloudflare/circl v1.3.9 // indirect
|
||||||
github.com/fatih/color v1.17.0 // indirect
|
github.com/fatih/color v1.17.0 // indirect
|
||||||
github.com/fsnotify/fsnotify v1.7.0 // indirect
|
github.com/fsnotify/fsnotify v1.7.0 // indirect
|
||||||
github.com/go-ole/go-ole v1.2.6 // indirect
|
github.com/go-ole/go-ole v1.2.6 // indirect
|
||||||
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 // indirect
|
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
|
||||||
github.com/gofrs/uuid/v5 v5.2.0 // indirect
|
github.com/gofrs/uuid/v5 v5.2.0 // indirect
|
||||||
github.com/google/gopacket v1.1.19 // indirect
|
github.com/google/gopacket v1.1.19 // indirect
|
||||||
github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7 // indirect
|
github.com/google/pprof v0.0.0-20240625030939-27f56978b8b0 // indirect
|
||||||
github.com/gopherjs/gopherjs v1.17.2 // indirect
|
|
||||||
github.com/gorilla/websocket v1.5.1 // indirect
|
github.com/gorilla/websocket v1.5.1 // indirect
|
||||||
github.com/hashicorp/errwrap v1.1.0 // indirect
|
github.com/hashicorp/errwrap v1.1.0 // indirect
|
||||||
github.com/hashicorp/go-multierror v1.1.1 // indirect
|
github.com/hashicorp/go-multierror v1.1.1 // indirect
|
||||||
github.com/hashicorp/hcl v1.0.0 // indirect
|
github.com/hashicorp/hcl v1.0.0 // indirect
|
||||||
github.com/huin/goupnp v1.2.0 // indirect
|
github.com/huin/goupnp v1.2.0 // indirect
|
||||||
github.com/imroc/req/v3 v3.43.7 // indirect
|
|
||||||
github.com/jackpal/go-nat-pmp v1.0.2 // indirect
|
github.com/jackpal/go-nat-pmp v1.0.2 // indirect
|
||||||
github.com/jtolds/gls v4.20.0+incompatible // indirect
|
github.com/klauspost/compress v1.17.9 // indirect
|
||||||
github.com/klauspost/compress v1.17.7 // indirect
|
|
||||||
github.com/koron/go-ssdp v0.0.4 // indirect
|
github.com/koron/go-ssdp v0.0.4 // indirect
|
||||||
github.com/libp2p/go-nat v0.2.0 // indirect
|
github.com/libp2p/go-nat v0.2.0 // indirect
|
||||||
github.com/libp2p/go-netroute v0.2.1 // indirect
|
github.com/libp2p/go-netroute v0.2.1 // indirect
|
||||||
@@ -48,22 +47,18 @@ require (
|
|||||||
github.com/mattn/go-isatty v0.0.20 // indirect
|
github.com/mattn/go-isatty v0.0.20 // indirect
|
||||||
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect
|
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect
|
||||||
github.com/mitchellh/mapstructure v1.5.0 // indirect
|
github.com/mitchellh/mapstructure v1.5.0 // indirect
|
||||||
github.com/moul/http2curl v1.0.0 // indirect
|
|
||||||
github.com/nxtrace/NTrace-core v1.3.1 // indirect
|
github.com/nxtrace/NTrace-core v1.3.1 // indirect
|
||||||
github.com/oneclickvirt/gostun v0.0.2-20240625025941 // indirect
|
github.com/onsi/ginkgo/v2 v2.19.0 // indirect
|
||||||
github.com/onsi/ginkgo/v2 v2.16.0 // indirect
|
|
||||||
github.com/oschwald/maxminddb-golang v1.12.0 // indirect
|
github.com/oschwald/maxminddb-golang v1.12.0 // indirect
|
||||||
github.com/parnurzeal/gorequest v0.3.0 // indirect
|
|
||||||
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
|
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
|
||||||
github.com/pion/dtls/v2 v2.2.7 // indirect
|
github.com/pion/dtls/v2 v2.2.7 // indirect
|
||||||
github.com/pion/logging v0.2.2 // indirect
|
github.com/pion/logging v0.2.2 // indirect
|
||||||
github.com/pion/stun/v2 v2.0.0 // indirect
|
github.com/pion/stun/v2 v2.0.0 // indirect
|
||||||
github.com/pion/transport/v2 v2.2.1 // indirect
|
github.com/pion/transport/v2 v2.2.1 // indirect
|
||||||
github.com/pion/transport/v3 v3.0.1 // indirect
|
github.com/pion/transport/v3 v3.0.1 // indirect
|
||||||
github.com/pkg/errors v0.9.1 // indirect
|
|
||||||
github.com/quic-go/qpack v0.4.0 // indirect
|
github.com/quic-go/qpack v0.4.0 // indirect
|
||||||
github.com/quic-go/quic-go v0.41.0 // indirect
|
github.com/quic-go/quic-go v0.45.1 // indirect
|
||||||
github.com/refraction-networking/utls v1.6.3 // indirect
|
github.com/refraction-networking/utls v1.6.6 // indirect
|
||||||
github.com/rivo/uniseg v0.4.7 // indirect
|
github.com/rivo/uniseg v0.4.7 // indirect
|
||||||
github.com/rodaine/table v1.2.0 // indirect
|
github.com/rodaine/table v1.2.0 // indirect
|
||||||
github.com/sagikazarmark/locafero v0.4.0 // indirect
|
github.com/sagikazarmark/locafero v0.4.0 // indirect
|
||||||
@@ -71,7 +66,6 @@ require (
|
|||||||
github.com/schollz/progressbar/v3 v3.14.4 // indirect
|
github.com/schollz/progressbar/v3 v3.14.4 // indirect
|
||||||
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
|
github.com/shirou/gopsutil v3.21.11+incompatible // indirect
|
||||||
github.com/showwin/speedtest-go v1.7.7 // indirect
|
github.com/showwin/speedtest-go v1.7.7 // indirect
|
||||||
github.com/smarty/assertions v1.16.0 // indirect
|
|
||||||
github.com/sourcegraph/conc v0.3.0 // indirect
|
github.com/sourcegraph/conc v0.3.0 // indirect
|
||||||
github.com/spf13/afero v1.11.0 // indirect
|
github.com/spf13/afero v1.11.0 // indirect
|
||||||
github.com/spf13/cast v1.6.0 // indirect
|
github.com/spf13/cast v1.6.0 // indirect
|
||||||
@@ -89,14 +83,14 @@ require (
|
|||||||
go.uber.org/multierr v1.11.0 // indirect
|
go.uber.org/multierr v1.11.0 // indirect
|
||||||
go.uber.org/zap v1.27.0 // indirect
|
go.uber.org/zap v1.27.0 // indirect
|
||||||
golang.org/x/crypto v0.24.0 // indirect
|
golang.org/x/crypto v0.24.0 // indirect
|
||||||
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 // indirect
|
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8 // indirect
|
||||||
golang.org/x/mod v0.17.0 // indirect
|
golang.org/x/mod v0.18.0 // indirect
|
||||||
golang.org/x/net v0.26.0 // indirect
|
golang.org/x/net v0.26.0 // indirect
|
||||||
golang.org/x/sync v0.7.0 // indirect
|
golang.org/x/sync v0.7.0 // indirect
|
||||||
golang.org/x/sys v0.21.0 // indirect
|
golang.org/x/sys v0.21.0 // indirect
|
||||||
golang.org/x/term v0.21.0 // indirect
|
golang.org/x/term v0.21.0 // indirect
|
||||||
golang.org/x/text v0.16.0 // indirect
|
golang.org/x/text v0.16.0 // indirect
|
||||||
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect
|
golang.org/x/tools v0.22.0 // indirect
|
||||||
gopkg.in/ini.v1 v1.67.0 // indirect
|
gopkg.in/ini.v1 v1.67.0 // indirect
|
||||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||||
)
|
)
|
||||||
|
111
go.sum
111
go.sum
@@ -4,14 +4,12 @@ github.com/andybalholm/brotli v1.1.0 h1:eLKJA0d02Lf0mVpIDgYnqXcUn0GqVmEFny3VuID1
|
|||||||
github.com/andybalholm/brotli v1.1.0/go.mod h1:sms7XGricyQI9K10gOSf56VKKWS4oLer58Q+mhRPtnY=
|
github.com/andybalholm/brotli v1.1.0/go.mod h1:sms7XGricyQI9K10gOSf56VKKWS4oLer58Q+mhRPtnY=
|
||||||
github.com/andybalholm/cascadia v1.3.2 h1:3Xi6Dw5lHF15JtdcmAHD3i1+T8plmv7BQ/nsViSLyss=
|
github.com/andybalholm/cascadia v1.3.2 h1:3Xi6Dw5lHF15JtdcmAHD3i1+T8plmv7BQ/nsViSLyss=
|
||||||
github.com/andybalholm/cascadia v1.3.2/go.mod h1:7gtRlve5FxPPgIgX36uWBX58OdBsSS6lUvCFb+h7KvU=
|
github.com/andybalholm/cascadia v1.3.2/go.mod h1:7gtRlve5FxPPgIgX36uWBX58OdBsSS6lUvCFb+h7KvU=
|
||||||
github.com/cloudflare/circl v1.3.7 h1:qlCDlTPz2n9fu58M0Nh1J/JzcFpfgkFHHX3O35r5vcU=
|
github.com/cloudflare/circl v1.3.9 h1:QFrlgFYf2Qpi8bSpVPK1HBvWpx16v/1TZivyo7pGuBE=
|
||||||
github.com/cloudflare/circl v1.3.7/go.mod h1:sRTcRWXGLrKw6yIGJ+l7amYJFfAXbZG0kBSc8r4zxgA=
|
github.com/cloudflare/circl v1.3.9/go.mod h1:PDRU+oXvdD7KCtgKxW95M5Z8BpSCJXQORiZFnBQS5QU=
|
||||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||||
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM=
|
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM=
|
||||||
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||||
github.com/elazarl/goproxy v0.0.0-20240618083138-03be62527ccb h1:2SoxRauy2IqekRMggrQk3yNI5X6omSnk6ugVbFywwXs=
|
|
||||||
github.com/elazarl/goproxy v0.0.0-20240618083138-03be62527ccb/go.mod h1:Ro8st/ElPeALwNFlcTpWmkr6IoMFfkjXAvTHpevnDsM=
|
|
||||||
github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4=
|
github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4=
|
||||||
github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI=
|
github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI=
|
||||||
github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8=
|
github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8=
|
||||||
@@ -22,20 +20,16 @@ github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ=
|
|||||||
github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
|
github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
|
||||||
github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY=
|
github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY=
|
||||||
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
|
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
|
||||||
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI=
|
github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI=
|
||||||
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls=
|
github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8=
|
||||||
github.com/gofrs/uuid/v5 v5.2.0 h1:qw1GMx6/y8vhVsx626ImfKMuS5CvJmhIKKtuyvfajMM=
|
github.com/gofrs/uuid/v5 v5.2.0 h1:qw1GMx6/y8vhVsx626ImfKMuS5CvJmhIKKtuyvfajMM=
|
||||||
github.com/gofrs/uuid/v5 v5.2.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8=
|
github.com/gofrs/uuid/v5 v5.2.0/go.mod h1:CDOjlDMVAtN56jqyRUZh58JT31Tiw7/oQyEXZV+9bD8=
|
||||||
github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg=
|
|
||||||
github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY=
|
|
||||||
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
|
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
|
||||||
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
|
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
|
||||||
github.com/google/gopacket v1.1.19 h1:ves8RnFZPGiFnTS0uPQStjwru6uO6h+nlr9j6fL7kF8=
|
github.com/google/gopacket v1.1.19 h1:ves8RnFZPGiFnTS0uPQStjwru6uO6h+nlr9j6fL7kF8=
|
||||||
github.com/google/gopacket v1.1.19/go.mod h1:iJ8V8n6KS+z2U1A8pUwu8bW5SyEMkXJB8Yo/Vo+TKTo=
|
github.com/google/gopacket v1.1.19/go.mod h1:iJ8V8n6KS+z2U1A8pUwu8bW5SyEMkXJB8Yo/Vo+TKTo=
|
||||||
github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7 h1:y3N7Bm7Y9/CtpiVkw/ZWj6lSlDF3F74SfKwfTCer72Q=
|
github.com/google/pprof v0.0.0-20240625030939-27f56978b8b0 h1:e+8XbKB6IMn8A4OAyZccO4pYfB3s7bt6azNIPE7AnPg=
|
||||||
github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik=
|
github.com/google/pprof v0.0.0-20240625030939-27f56978b8b0/go.mod h1:K1liHPHnj73Fdn/EKuT8nrFqBihUSKXoLYU0BuatOYo=
|
||||||
github.com/gopherjs/gopherjs v1.17.2 h1:fQnZVsXk8uxXIStYb0N4bGk7jeyTalG/wsZjQ25dO0g=
|
|
||||||
github.com/gopherjs/gopherjs v1.17.2/go.mod h1:pRRIvn/QzFLrKfvEz3qUuEhtE/zLCWfreZ6J5gM2i+k=
|
|
||||||
github.com/gorilla/websocket v1.5.1 h1:gmztn0JnHVt9JZquRuzLw3g4wouNVzKL15iLr/zn/QY=
|
github.com/gorilla/websocket v1.5.1 h1:gmztn0JnHVt9JZquRuzLw3g4wouNVzKL15iLr/zn/QY=
|
||||||
github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY=
|
github.com/gorilla/websocket v1.5.1/go.mod h1:x3kM2JMyaluk02fnUJpQuwD2dCS5NDG2ZHL0uE0tcaY=
|
||||||
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||||
@@ -51,11 +45,9 @@ github.com/imroc/req/v3 v3.43.7 h1:dOcNb9n0X83N5/5/AOkiU+cLhzx8QFXjv5MhikazzQA=
|
|||||||
github.com/imroc/req/v3 v3.43.7/go.mod h1:SQIz5iYop16MJxbo8ib+4LnostGCok8NQf8ToyQc2xA=
|
github.com/imroc/req/v3 v3.43.7/go.mod h1:SQIz5iYop16MJxbo8ib+4LnostGCok8NQf8ToyQc2xA=
|
||||||
github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus=
|
github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus=
|
||||||
github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc=
|
github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc=
|
||||||
github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo=
|
|
||||||
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
|
|
||||||
github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213/go.mod h1:vNUNkEQ1e29fT/6vq2aBdFsgNPmy8qMdSay1npru+Sw=
|
github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213/go.mod h1:vNUNkEQ1e29fT/6vq2aBdFsgNPmy8qMdSay1npru+Sw=
|
||||||
github.com/klauspost/compress v1.17.7 h1:ehO88t2UGzQK66LMdE8tibEd1ErmzZjNEqWkjLAKQQg=
|
github.com/klauspost/compress v1.17.9 h1:6KIumPrER1LHsvBVuDa0r5xaG0Es51mhhB9BQB2qeMA=
|
||||||
github.com/klauspost/compress v1.17.7/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw=
|
github.com/klauspost/compress v1.17.9/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw=
|
||||||
github.com/koron/go-ssdp v0.0.4 h1:1IDwrghSKYM7yLf7XCzbByg2sJ/JcNOZRXS2jczTwz0=
|
github.com/koron/go-ssdp v0.0.4 h1:1IDwrghSKYM7yLf7XCzbByg2sJ/JcNOZRXS2jczTwz0=
|
||||||
github.com/koron/go-ssdp v0.0.4/go.mod h1:oDXq+E5IL5q0U8uSBcoAXzTzInwy5lEgC91HoKtbmZk=
|
github.com/koron/go-ssdp v0.0.4/go.mod h1:oDXq+E5IL5q0U8uSBcoAXzTzInwy5lEgC91HoKtbmZk=
|
||||||
github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
|
github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
|
||||||
@@ -81,56 +73,42 @@ github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db h1:62I3jR2Em
|
|||||||
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db/go.mod h1:l0dey0ia/Uv7NcFFVbCLtqEBQbrT4OCwCSKTEv6enCw=
|
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db/go.mod h1:l0dey0ia/Uv7NcFFVbCLtqEBQbrT4OCwCSKTEv6enCw=
|
||||||
github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY=
|
github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY=
|
||||||
github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
|
github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo=
|
||||||
github.com/moul/http2curl v1.0.0 h1:dRMWoAtb+ePxMlLkrCbAqh4TlPHXvoGUSQ323/9Zahs=
|
|
||||||
github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ=
|
|
||||||
github.com/nxtrace/NTrace-core v1.3.1 h1:f4z5UaZEuhUP/g6xElpZ2bo+guWITJVrMKrJTqd27oc=
|
github.com/nxtrace/NTrace-core v1.3.1 h1:f4z5UaZEuhUP/g6xElpZ2bo+guWITJVrMKrJTqd27oc=
|
||||||
github.com/nxtrace/NTrace-core v1.3.1/go.mod h1:0Px/Zc60qk6cssmP+yv4kstFxvX9sXqDduoVqBO+qf8=
|
github.com/nxtrace/NTrace-core v1.3.1/go.mod h1:0Px/Zc60qk6cssmP+yv4kstFxvX9sXqDduoVqBO+qf8=
|
||||||
github.com/oneclickvirt/CommonMediaTests v0.0.2-20240630023003 h1:8jQFqDK5m7V9xlLBk8rSUYDyi3u5xzf5kqwEx5b+/7g=
|
github.com/oneclickvirt/CommonMediaTests v0.0.2-20240630023003 h1:8jQFqDK5m7V9xlLBk8rSUYDyi3u5xzf5kqwEx5b+/7g=
|
||||||
github.com/oneclickvirt/CommonMediaTests v0.0.2-20240630023003/go.mod h1:DAmFPRjFV5p9fEzUUSml5jJGn2f1NZJQCzTxITHDjc4=
|
github.com/oneclickvirt/CommonMediaTests v0.0.2-20240630023003/go.mod h1:DAmFPRjFV5p9fEzUUSml5jJGn2f1NZJQCzTxITHDjc4=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.7-20240624115527 h1:rMC+aLDkvOe9K+AXjUt/IMAOx1LieyBv6DN/0/2ww7Q=
|
github.com/oneclickvirt/CommonMediaTests v0.0.3-20240702073302 h1:JbgWWVL6WR44H/dqpBLdet0M7lM/YrnwGEG40FmawRo=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.7-20240624115527/go.mod h1:HP3CvAS+AJWxxY+BVbxIOlvaQ87YOSge89vAMG52b5o=
|
github.com/oneclickvirt/CommonMediaTests v0.0.3-20240702073302/go.mod h1:DAmFPRjFV5p9fEzUUSml5jJGn2f1NZJQCzTxITHDjc4=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.9-20240630032239 h1:b2tf2AVZtTmDvOOtm7tmeOCqFJPm7fe2mF/0Kk15Mhk=
|
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.9-20240630032239/go.mod h1:HP3CvAS+AJWxxY+BVbxIOlvaQ87YOSge89vAMG52b5o=
|
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.10-20240630041851 h1:YC/Phn7I4hxlj+WvNfO7uHfKOSiNvd+3JA1vVkqKv1M=
|
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.10-20240630041851/go.mod h1:HP3CvAS+AJWxxY+BVbxIOlvaQ87YOSge89vAMG52b5o=
|
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930 h1:/Sc4Eas1Pso18ak93wlazkuMKRRElCntITja/0opOpM=
|
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930 h1:/Sc4Eas1Pso18ak93wlazkuMKRRElCntITja/0opOpM=
|
||||||
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930/go.mod h1:HP3CvAS+AJWxxY+BVbxIOlvaQ87YOSge89vAMG52b5o=
|
github.com/oneclickvirt/UnlockTests v0.0.10-20240630044930/go.mod h1:HP3CvAS+AJWxxY+BVbxIOlvaQ87YOSge89vAMG52b5o=
|
||||||
github.com/oneclickvirt/backtrace v0.0.4-20240624090335 h1:0LP5KyA6GLlqQAtOF0uyBSAykHJrzOA96Eb87qUhGQw=
|
github.com/oneclickvirt/backtrace v0.0.4-20240624090335 h1:0LP5KyA6GLlqQAtOF0uyBSAykHJrzOA96Eb87qUhGQw=
|
||||||
github.com/oneclickvirt/backtrace v0.0.4-20240624090335/go.mod h1:zvsC7xY/WZqs5KL2JB967OVnuqjNbxu9bW6wXRLo5h8=
|
github.com/oneclickvirt/backtrace v0.0.4-20240624090335/go.mod h1:zvsC7xY/WZqs5KL2JB967OVnuqjNbxu9bW6wXRLo5h8=
|
||||||
github.com/oneclickvirt/basics v0.0.3-20240625075226 h1:K9VriCHIYnXPZXBSn9PRQX+jBS6AIFH8tBVb/i8VGAw=
|
github.com/oneclickvirt/basics v0.0.5-20240702055351 h1:Ez9iLNAr+A8AA3EdcDh1aB/XVSWjwSKjhgMUySkcSSY=
|
||||||
github.com/oneclickvirt/basics v0.0.3-20240625075226/go.mod h1:dTB+/oyFQYfTYX55rFJVWatum5F9g62zjfmHCM6Vj1s=
|
github.com/oneclickvirt/basics v0.0.5-20240702055351/go.mod h1:CjcPkpy/ClTgrwB6YJtBi//lvseHAWYmsbTrOOm+zCs=
|
||||||
github.com/oneclickvirt/cputest v0.0.5-20240630022206 h1:L+Su9CNpERf7ZwJZPhvasZdXrlEt6VfqZQpuaPntzkI=
|
github.com/oneclickvirt/cputest v0.0.8-20240702070215 h1:CcFpyVPlQkJ6vjFP17BRuJhh/afiJhOhZ0BW+TtfVDg=
|
||||||
github.com/oneclickvirt/cputest v0.0.5-20240630022206/go.mod h1:wh4fGT3KFG9qztew5eBL9EfWr8WeZPBLsq60ZzudU4g=
|
github.com/oneclickvirt/cputest v0.0.8-20240702070215/go.mod h1:MmaHN9+XMntI3rLycwj8Ne31fG18IfNoa8N2utDK1CY=
|
||||||
github.com/oneclickvirt/defaultset v0.0.2-20240624082446 h1:5Pg3mK/u/vQvSz7anu0nxzrNdELi/AcDAU1mMsmPzyc=
|
github.com/oneclickvirt/defaultset v0.0.2-20240624082446 h1:5Pg3mK/u/vQvSz7anu0nxzrNdELi/AcDAU1mMsmPzyc=
|
||||||
github.com/oneclickvirt/defaultset v0.0.2-20240624082446/go.mod h1:e9Jt4tf2sbemCtc84/XgKcHy9EZ2jkc5x2sW1NiJS+E=
|
github.com/oneclickvirt/defaultset v0.0.2-20240624082446/go.mod h1:e9Jt4tf2sbemCtc84/XgKcHy9EZ2jkc5x2sW1NiJS+E=
|
||||||
github.com/oneclickvirt/disktest v0.0.3-20240629152513 h1:ZW7MBMd2HxQi1ktg/ztVI2A10JzF4ZI6I7ATZvcK9w8=
|
github.com/oneclickvirt/disktest v0.0.4-20240702071738 h1:3rErTS9RwU8jAmGc8LqjtFBBd94lIk+wSWpohI55C/w=
|
||||||
github.com/oneclickvirt/disktest v0.0.3-20240629152513/go.mod h1:x7VAJF0Ks05FyE4BI5xedXNKmwbeXfp8GCRALAIlueI=
|
github.com/oneclickvirt/disktest v0.0.4-20240702071738/go.mod h1:wIZy8G6Mbcy8Op8tc0HmJNpbJQQ5A15fvnUqMJXIdO0=
|
||||||
github.com/oneclickvirt/gostun v0.0.2-20240625025941 h1:h+ZL8jkjXR6QE0qEX34FjWTv89+lNj2fEkWx5Agpgzc=
|
github.com/oneclickvirt/gostun v0.0.3-20240702054621 h1:IE89eEYV9TJbF94SakQDAxTLIaqX+Tb6ZhJ/CCIP+90=
|
||||||
github.com/oneclickvirt/gostun v0.0.2-20240625025941/go.mod h1:f7DPEXAxbmwXSW33dbxtb0/KzqvOBWhTs2Or5xBerQA=
|
github.com/oneclickvirt/gostun v0.0.3-20240702054621/go.mod h1:f7DPEXAxbmwXSW33dbxtb0/KzqvOBWhTs2Or5xBerQA=
|
||||||
github.com/oneclickvirt/memorytest v0.0.1-20240624151629 h1:2rJAB3gFGlFPocIb/WRVWYqs4nr2jGYokfDOgqFicD4=
|
github.com/oneclickvirt/memorytest v0.0.2-20240702031042 h1:j+LsjOh5glYiidqtSqjZJRw694LYW1PHLMh6AovluTQ=
|
||||||
github.com/oneclickvirt/memorytest v0.0.1-20240624151629/go.mod h1:+YNzy+NeVg61d0kNwSyVDqHyVtKzjuRe1NvMzsDLg0I=
|
github.com/oneclickvirt/memorytest v0.0.2-20240702031042/go.mod h1:+YNzy+NeVg61d0kNwSyVDqHyVtKzjuRe1NvMzsDLg0I=
|
||||||
github.com/oneclickvirt/nt3 v0.0.1-20240627070009 h1:020pqkdGDnkIIpyNbbS1sjG1uIl3GgjeNgVqJzAw0ng=
|
github.com/oneclickvirt/nt3 v0.0.2-20240630152642 h1:BkpR1j9JaDxMzx7iIwtsnFDxSldjYr2TUYpZE7m8z/Y=
|
||||||
github.com/oneclickvirt/nt3 v0.0.1-20240627070009/go.mod h1:Vb724PgpP17W09mLw5I2UZZAuYbY8WwGlKZdxRDFr0Y=
|
github.com/oneclickvirt/nt3 v0.0.2-20240630152642/go.mod h1:UojPmtangn17TiQaDccVrZbn6sZwJOtzBgg3idp68cA=
|
||||||
github.com/oneclickvirt/portchecker v0.0.1-20240624155429 h1:+wapaOcFrg1iWJDhBKThDzppyIMY7hWxK7F5RBkZg4o=
|
github.com/oneclickvirt/portchecker v0.0.1-20240624155429 h1:+wapaOcFrg1iWJDhBKThDzppyIMY7hWxK7F5RBkZg4o=
|
||||||
github.com/oneclickvirt/portchecker v0.0.1-20240624155429/go.mod h1:HQxSTrqM8/QFqHMTBZ7S8H9eEO5FkUXU1eb7ZX5Mk+k=
|
github.com/oneclickvirt/portchecker v0.0.1-20240624155429/go.mod h1:HQxSTrqM8/QFqHMTBZ7S8H9eEO5FkUXU1eb7ZX5Mk+k=
|
||||||
github.com/oneclickvirt/security v0.0.1-20240625075931 h1:Vj1Wq/JVcqYpfqUWRtsITbz3zM4HxnLC0iPxxA6akP0=
|
github.com/oneclickvirt/security v0.0.4-20240702055848 h1:UCfjfoslcfKhCvJm37jQmhJ+O8d4lL+uvBJVcLAXc2s=
|
||||||
github.com/oneclickvirt/security v0.0.1-20240625075931/go.mod h1:6bjZjpYJ8M3aRIcLP61b0mjYRwvtWbYkvoGjS28Bdy4=
|
github.com/oneclickvirt/security v0.0.4-20240702055848/go.mod h1:YKmO3FRWjhHYJ5rKqz+1H3hB6sCA4gioik7r8GMfyqo=
|
||||||
github.com/oneclickvirt/security v0.0.1-20240630101628 h1:Ain+TvrWo22ex9CGc1Z2seOX32XIXW8ajs2K3sfd+JY=
|
|
||||||
github.com/oneclickvirt/security v0.0.1-20240630101628/go.mod h1:6bjZjpYJ8M3aRIcLP61b0mjYRwvtWbYkvoGjS28Bdy4=
|
|
||||||
github.com/oneclickvirt/speedtest v0.0.4-20240629100548 h1:DQA0R/EdtmLJrQBb9JvQBaBpcMgiGDvIHq+0quNZQQM=
|
|
||||||
github.com/oneclickvirt/speedtest v0.0.4-20240629100548/go.mod h1:JNIxUbEJD12w81b7754RLHD55fsH6wHj+fCV2PqBDhk=
|
|
||||||
github.com/oneclickvirt/speedtest v0.0.5-20240630045424 h1:LXvoAgCAJVGci0Tzm3cDgvNaezncS8R5nOn8s+p+kNA=
|
|
||||||
github.com/oneclickvirt/speedtest v0.0.5-20240630045424/go.mod h1:zd5ZgIGslmtQLQehEfRjyumlvgDHTpCSMchKfKXoASI=
|
|
||||||
github.com/oneclickvirt/speedtest v0.0.6-20240630114816 h1:gI2hqV0IwcvGqYzLhlt4w2oZvYhCL+73jftUuJYBsuI=
|
github.com/oneclickvirt/speedtest v0.0.6-20240630114816 h1:gI2hqV0IwcvGqYzLhlt4w2oZvYhCL+73jftUuJYBsuI=
|
||||||
github.com/oneclickvirt/speedtest v0.0.6-20240630114816/go.mod h1:zd5ZgIGslmtQLQehEfRjyumlvgDHTpCSMchKfKXoASI=
|
github.com/oneclickvirt/speedtest v0.0.6-20240630114816/go.mod h1:zd5ZgIGslmtQLQehEfRjyumlvgDHTpCSMchKfKXoASI=
|
||||||
github.com/onsi/ginkgo/v2 v2.16.0 h1:7q1w9frJDzninhXxjZd+Y/x54XNjG/UlRLIYPZafsPM=
|
github.com/onsi/ginkgo/v2 v2.19.0 h1:9Cnnf7UHo57Hy3k6/m5k3dRfGTMXGvxhHFvkDTCTpvA=
|
||||||
github.com/onsi/ginkgo/v2 v2.16.0/go.mod h1:llBI3WDLL9Z6taip6f33H76YcWtJv+7R3HigUjbIBOs=
|
github.com/onsi/ginkgo/v2 v2.19.0/go.mod h1:rlwLi9PilAFJ8jCg9UE1QP6VBpd6/xj3SRC0d6TU0To=
|
||||||
github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8=
|
github.com/onsi/gomega v1.33.1 h1:dsYjIxxSR755MDmKVsaFQTE22ChNBcuuTWgkUDSubOk=
|
||||||
github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ=
|
github.com/onsi/gomega v1.33.1/go.mod h1:U4R44UsT+9eLIaYRB2a5qajjtQYn0hauxvRm16AVYg0=
|
||||||
github.com/oschwald/maxminddb-golang v1.12.0 h1:9FnTOD0YOhP7DGxGsq4glzpGy5+w7pq50AS6wALUMYs=
|
github.com/oschwald/maxminddb-golang v1.12.0 h1:9FnTOD0YOhP7DGxGsq4glzpGy5+w7pq50AS6wALUMYs=
|
||||||
github.com/oschwald/maxminddb-golang v1.12.0/go.mod h1:q0Nob5lTCqyQ8WT6FYgS1L7PXKVVbgiymefNwIjPzgY=
|
github.com/oschwald/maxminddb-golang v1.12.0/go.mod h1:q0Nob5lTCqyQ8WT6FYgS1L7PXKVVbgiymefNwIjPzgY=
|
||||||
github.com/parnurzeal/gorequest v0.3.0 h1:SoFyqCDC9COr1xuS6VA8fC8RU7XyrJZN2ona1kEX7FI=
|
|
||||||
github.com/parnurzeal/gorequest v0.3.0/go.mod h1:3Kh2QUMJoqw3icWAecsyzkpY7UzRfDhbRdTjtNwNiUE=
|
|
||||||
github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM=
|
github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM=
|
||||||
github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs=
|
github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs=
|
||||||
github.com/pion/dtls/v2 v2.2.7 h1:cSUBsETxepsCSFSxC3mc/aDo14qQLMSL+O6IjG28yV8=
|
github.com/pion/dtls/v2 v2.2.7 h1:cSUBsETxepsCSFSxC3mc/aDo14qQLMSL+O6IjG28yV8=
|
||||||
@@ -143,17 +121,15 @@ github.com/pion/transport/v2 v2.2.1 h1:7qYnCBlpgSJNYMbLCKuSY9KbQdBFoETvPNETv0y4N
|
|||||||
github.com/pion/transport/v2 v2.2.1/go.mod h1:cXXWavvCnFF6McHTft3DWS9iic2Mftcz1Aq29pGcU5g=
|
github.com/pion/transport/v2 v2.2.1/go.mod h1:cXXWavvCnFF6McHTft3DWS9iic2Mftcz1Aq29pGcU5g=
|
||||||
github.com/pion/transport/v3 v3.0.1 h1:gDTlPJwROfSfz6QfSi0ZmeCSkFcnWWiiR9ES0ouANiM=
|
github.com/pion/transport/v3 v3.0.1 h1:gDTlPJwROfSfz6QfSi0ZmeCSkFcnWWiiR9ES0ouANiM=
|
||||||
github.com/pion/transport/v3 v3.0.1/go.mod h1:UY7kiITrlMv7/IKgd5eTUcaahZx5oUN3l9SzK5f5xE0=
|
github.com/pion/transport/v3 v3.0.1/go.mod h1:UY7kiITrlMv7/IKgd5eTUcaahZx5oUN3l9SzK5f5xE0=
|
||||||
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
|
|
||||||
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
|
||||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||||
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U=
|
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U=
|
||||||
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||||
github.com/quic-go/qpack v0.4.0 h1:Cr9BXA1sQS2SmDUWjSofMPNKmvF6IiIfDRmgU0w1ZCo=
|
github.com/quic-go/qpack v0.4.0 h1:Cr9BXA1sQS2SmDUWjSofMPNKmvF6IiIfDRmgU0w1ZCo=
|
||||||
github.com/quic-go/qpack v0.4.0/go.mod h1:UZVnYIfi5GRk+zI9UMaCPsmZ2xKJP7XBUvVyT1Knj9A=
|
github.com/quic-go/qpack v0.4.0/go.mod h1:UZVnYIfi5GRk+zI9UMaCPsmZ2xKJP7XBUvVyT1Knj9A=
|
||||||
github.com/quic-go/quic-go v0.41.0 h1:aD8MmHfgqTURWNJy48IYFg2OnxwHT3JL7ahGs73lb4k=
|
github.com/quic-go/quic-go v0.45.1 h1:tPfeYCk+uZHjmDRwHHQmvHRYL2t44ROTujLeFVBmjCA=
|
||||||
github.com/quic-go/quic-go v0.41.0/go.mod h1:qCkNjqczPEvgsOnxZ0eCD14lv+B2LHlFAB++CNOh9hA=
|
github.com/quic-go/quic-go v0.45.1/go.mod h1:1dLehS7TIR64+vxGR70GDcatWTOtMX2PUtnKsjbTurI=
|
||||||
github.com/refraction-networking/utls v1.6.3 h1:MFOfRN35sSx6K5AZNIoESsBuBxS2LCgRilRIdHb6fDc=
|
github.com/refraction-networking/utls v1.6.6 h1:igFsYBUJPYM8Rno9xUuDoM5GQrVEqY4llzEXOkL43Ig=
|
||||||
github.com/refraction-networking/utls v1.6.3/go.mod h1:yil9+7qSl+gBwJqztoQseO6Pr3h62pQoY1lXiNR/FPs=
|
github.com/refraction-networking/utls v1.6.6/go.mod h1:BC3O4vQzye5hqpmDTWUqi4P5DDhzJfkV1tdqtawQIH0=
|
||||||
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
|
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
|
||||||
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
|
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
|
||||||
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
|
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
|
||||||
@@ -171,10 +147,6 @@ github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKl
|
|||||||
github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
|
github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
|
||||||
github.com/showwin/speedtest-go v1.7.7 h1:VmK75SZOTKiuWjIVrs+mo7ZoKEw0utiGCvpnurS0olU=
|
github.com/showwin/speedtest-go v1.7.7 h1:VmK75SZOTKiuWjIVrs+mo7ZoKEw0utiGCvpnurS0olU=
|
||||||
github.com/showwin/speedtest-go v1.7.7/go.mod h1:uLgdWCNarXxlYsL2E5TOZpCIwpgSWnEANZp7gfHXHu0=
|
github.com/showwin/speedtest-go v1.7.7/go.mod h1:uLgdWCNarXxlYsL2E5TOZpCIwpgSWnEANZp7gfHXHu0=
|
||||||
github.com/smarty/assertions v1.16.0 h1:EvHNkdRA4QHMrn75NZSoUQ/mAUXAYWfatfB01yTCzfY=
|
|
||||||
github.com/smarty/assertions v1.16.0/go.mod h1:duaaFdCS0K9dnoM50iyek/eYINOZ64gbh1Xlf6LG7AI=
|
|
||||||
github.com/smartystreets/goconvey v1.8.1 h1:qGjIddxOk4grTu9JPOU31tVfq3cNdBlNa5sSznIX1xY=
|
|
||||||
github.com/smartystreets/goconvey v1.8.1/go.mod h1:+/u4qLyY6x1jReYOp7GOM2FSt8aP9CzCZL03bI28W60=
|
|
||||||
github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo=
|
github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo=
|
||||||
github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0=
|
github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0=
|
||||||
github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8=
|
github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8=
|
||||||
@@ -190,7 +162,6 @@ github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSS
|
|||||||
github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo=
|
github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo=
|
||||||
github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA=
|
github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA=
|
||||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||||
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
|
||||||
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||||
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
|
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
|
||||||
github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
|
github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
|
||||||
@@ -230,14 +201,14 @@ golang.org/x/crypto v0.8.0/go.mod h1:mRqEX+O9/h5TFCrQhkgjo2yKi0yYA+9ecGkdQoHrywE
|
|||||||
golang.org/x/crypto v0.12.0/go.mod h1:NF0Gs7EO5K4qLn+Ylc+fih8BSTeIjAP05siRnAh98yw=
|
golang.org/x/crypto v0.12.0/go.mod h1:NF0Gs7EO5K4qLn+Ylc+fih8BSTeIjAP05siRnAh98yw=
|
||||||
golang.org/x/crypto v0.24.0 h1:mnl8DM0o513X8fdIkmyFE/5hTYxbwYOjDS/+rK6qpRI=
|
golang.org/x/crypto v0.24.0 h1:mnl8DM0o513X8fdIkmyFE/5hTYxbwYOjDS/+rK6qpRI=
|
||||||
golang.org/x/crypto v0.24.0/go.mod h1:Z1PMYSOR5nyMcyAVAIQSKCDwalqy85Aqn1x3Ws4L5DM=
|
golang.org/x/crypto v0.24.0/go.mod h1:Z1PMYSOR5nyMcyAVAIQSKCDwalqy85Aqn1x3Ws4L5DM=
|
||||||
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 h1:vr/HnozRka3pE4EsMEg1lgkXJkTFJCVUX+S/ZT6wYzM=
|
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8 h1:yixxcjnhBmY0nkL253HFVIm0JsFHwrHdT3Yh6szTnfY=
|
||||||
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842/go.mod h1:XtvwrStGgqGPLc4cjQfWqZHG1YFdYs6swckp8vpsjnc=
|
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8/go.mod h1:jj3sYF3dwk5D+ghuXyeI3r5MFf+NT2An6/9dOA95KSI=
|
||||||
golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
|
golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
|
||||||
golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
|
golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
|
||||||
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4=
|
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4=
|
||||||
golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
|
golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
|
||||||
golang.org/x/mod v0.17.0 h1:zY54UmvipHiNd+pm+m0x9KhZ9hl1/7QNMyxXbc6ICqA=
|
golang.org/x/mod v0.18.0 h1:5+9lSbEzPSdWkH32vYPBwEpX8KwDbM52Ud9xBUvNlb0=
|
||||||
golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c=
|
golang.org/x/mod v0.18.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c=
|
||||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||||
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
|
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
|
||||||
@@ -287,17 +258,19 @@ golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
|
|||||||
golang.org/x/text v0.12.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE=
|
golang.org/x/text v0.12.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE=
|
||||||
golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4=
|
golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4=
|
||||||
golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI=
|
golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI=
|
||||||
|
golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk=
|
||||||
|
golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM=
|
||||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||||
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||||
golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
|
golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
|
||||||
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
|
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
|
||||||
golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU=
|
golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU=
|
||||||
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d h1:vU5i/LfpvrRCpgM/VPfJLg5KjxD3E+hfT1SH+d9zLwg=
|
golang.org/x/tools v0.22.0 h1:gqSGLZqv+AI9lIQzniJ0nZDRG5GBPsSi+DRNHWNz6yA=
|
||||||
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk=
|
golang.org/x/tools v0.22.0/go.mod h1:aCwcsjqvq7Yqt6TNyX7QMU2enbQ/Gt0bo6krSeEri+c=
|
||||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||||
google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8=
|
google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI=
|
||||||
google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
|
google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos=
|
||||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
|
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
|
||||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
|
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
|
||||||
|
526
goecs.go
526
goecs.go
@@ -3,6 +3,11 @@ package main
|
|||||||
import (
|
import (
|
||||||
"flag"
|
"flag"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/oneclickvirt/CommonMediaTests/commediatests"
|
||||||
|
backtraceori "github.com/oneclickvirt/backtrace/bk"
|
||||||
|
basicmodel "github.com/oneclickvirt/basics/model"
|
||||||
|
cputestmodel "github.com/oneclickvirt/cputest/model"
|
||||||
|
disktestmodel "github.com/oneclickvirt/disktest/disk"
|
||||||
"github.com/oneclickvirt/ecs/backtrace"
|
"github.com/oneclickvirt/ecs/backtrace"
|
||||||
"github.com/oneclickvirt/ecs/commediatest"
|
"github.com/oneclickvirt/ecs/commediatest"
|
||||||
"github.com/oneclickvirt/ecs/cputest"
|
"github.com/oneclickvirt/ecs/cputest"
|
||||||
@@ -12,176 +17,439 @@ import (
|
|||||||
"github.com/oneclickvirt/ecs/speedtest"
|
"github.com/oneclickvirt/ecs/speedtest"
|
||||||
"github.com/oneclickvirt/ecs/unlocktest"
|
"github.com/oneclickvirt/ecs/unlocktest"
|
||||||
"github.com/oneclickvirt/ecs/utils"
|
"github.com/oneclickvirt/ecs/utils"
|
||||||
|
gostunmodel "github.com/oneclickvirt/gostun/model"
|
||||||
|
memorytestmodel "github.com/oneclickvirt/memorytest/memory"
|
||||||
"github.com/oneclickvirt/portchecker/email"
|
"github.com/oneclickvirt/portchecker/email"
|
||||||
|
speedtestmodel "github.com/oneclickvirt/speedtest/model"
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"os/signal"
|
||||||
"regexp"
|
"regexp"
|
||||||
"runtime"
|
"runtime"
|
||||||
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
|
"syscall"
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
ecsVersion = "2024.06.30"
|
ecsVersion = "v0.0.30"
|
||||||
showVersion bool
|
menuMode bool
|
||||||
language string
|
input, choice string
|
||||||
cpuTestMethod, cpuTestThreadMode string
|
showVersion bool
|
||||||
memoryTestMethod string
|
enableLogger bool
|
||||||
diskTestMethod, diskTestPath string
|
language string
|
||||||
diskMultiCheck bool
|
cpuTestMethod, cpuTestThreadMode string
|
||||||
nt3CheckType, nt3Location string
|
memoryTestMethod string
|
||||||
spNum int
|
diskTestMethod, diskTestPath string
|
||||||
width = 84
|
diskMultiCheck bool
|
||||||
|
nt3CheckType, nt3Location string
|
||||||
|
spNum int
|
||||||
|
width = 82
|
||||||
|
basicStatus, cpuTestStatus, memoryTestStatus, diskTestStatus bool
|
||||||
|
commTestStatus, utTestStatus, securityTestStatus, emailTestStatus bool
|
||||||
|
backtraceStatus, nt3Status, speedTestStatus bool
|
||||||
|
filePath = "goecs.txt"
|
||||||
|
enabelUpload = true
|
||||||
|
help bool
|
||||||
|
goecsFlag = flag.NewFlagSet("goecs", flag.ContinueOnError)
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.BoolVar(&showVersion, "v", false, "Show version information")
|
goecsFlag.BoolVar(&help, "h", false, "Show help information")
|
||||||
flag.StringVar(&language, "l", "zh", "Specify language (supported: en, zh)")
|
goecsFlag.BoolVar(&showVersion, "v", false, "Display version information")
|
||||||
flag.StringVar(&cpuTestMethod, "cpum", "sysbench", "Specify CPU test method (supported: sysbench, geekbench, winsat)")
|
goecsFlag.BoolVar(&menuMode, "menu", true, "Enable/Disable menu mode, disable example: -menu=false") // true 默认启用菜单栏模式
|
||||||
flag.StringVar(&cpuTestThreadMode, "cput", "multi", "Specify CPU test thread mode (supported: single multi)")
|
goecsFlag.StringVar(&language, "l", "zh", "Set language (supported: en, zh)")
|
||||||
flag.StringVar(&memoryTestMethod, "memorym", "dd", "Specify Memory test method (supported: sysbench, dd, winsat)")
|
goecsFlag.BoolVar(&basicStatus, "basic", true, "Enable/Disable basic test")
|
||||||
flag.StringVar(&diskTestMethod, "diskm", "fio", "Specify Disk test method (supported: fio, dd, winsat)")
|
goecsFlag.BoolVar(&cpuTestStatus, "cpu", true, "Enable/Disable CPU test")
|
||||||
flag.StringVar(&diskTestPath, "diskp", "", "Specify Disk test path, example: -diskp /root")
|
goecsFlag.BoolVar(&memoryTestStatus, "memory", true, "Enable/Disable memory test")
|
||||||
flag.BoolVar(&diskMultiCheck, "diskmc", false, "Enable multiple disk checks, example: -diskmc=false")
|
goecsFlag.BoolVar(&diskTestStatus, "disk", true, "Enable/Disable disk test")
|
||||||
flag.StringVar(&nt3Location, "nt3loc", "GZ", "指定三网回程路由检测的地址,支持 GZ, SH, BJ, CD 对应 广州,上海,北京,成都")
|
goecsFlag.BoolVar(&commTestStatus, "comm", true, "Enable/Disable common media test")
|
||||||
flag.StringVar(&nt3CheckType, "nt3t", "ipv4", "指定三网回程路由检测的类型,支持 both, ipv4, ipv6")
|
goecsFlag.BoolVar(&utTestStatus, "ut", true, "Enable/Disable unlock media test")
|
||||||
flag.IntVar(&spNum, "spnum", 2, "Specify speedtest each operator servers num")
|
goecsFlag.BoolVar(&securityTestStatus, "security", true, "Enable/Disable security test")
|
||||||
flag.Parse()
|
goecsFlag.BoolVar(&emailTestStatus, "email", true, "Enable/Disable email port test")
|
||||||
|
goecsFlag.BoolVar(&backtraceStatus, "backtrace", true, "Enable/Disable backtrace test (in 'en' language or on windows it always false)")
|
||||||
|
goecsFlag.BoolVar(&nt3Status, "nt3", true, "Enable/Disable NT3 test (in 'en' language or on windows it always false)")
|
||||||
|
goecsFlag.BoolVar(&speedTestStatus, "speed", true, "Enable/Disable speed test")
|
||||||
|
goecsFlag.StringVar(&cpuTestMethod, "cpum", "sysbench", "Set CPU test method (supported: sysbench, geekbench, winsat)")
|
||||||
|
goecsFlag.StringVar(&cpuTestThreadMode, "cput", "multi", "Set CPU test thread mode (supported: single, multi)")
|
||||||
|
goecsFlag.StringVar(&memoryTestMethod, "memorym", "dd", "Set memory test method (supported: sysbench, dd, winsat)")
|
||||||
|
goecsFlag.StringVar(&diskTestMethod, "diskm", "fio", "Set disk test method (supported: fio, dd, winsat)")
|
||||||
|
goecsFlag.StringVar(&diskTestPath, "diskp", "", "Set disk test path, e.g., -diskp /root")
|
||||||
|
goecsFlag.BoolVar(&diskMultiCheck, "diskmc", false, "Enable/Disable multiple disk checks, e.g., -diskmc=false")
|
||||||
|
goecsFlag.StringVar(&nt3Location, "nt3loc", "GZ", "Specify NT3 test location (supported: GZ, SH, BJ, CD for Guangzhou, Shanghai, Beijing, Chengdu)")
|
||||||
|
goecsFlag.StringVar(&nt3CheckType, "nt3t", "ipv4", "Set NT3 test type (supported: both, ipv4, ipv6)")
|
||||||
|
goecsFlag.IntVar(&spNum, "spnum", 2, "Set the number of servers per operator for speed test")
|
||||||
|
goecsFlag.BoolVar(&enableLogger, "log", false, "Enable/Disable logging in the current path")
|
||||||
|
goecsFlag.Parse(os.Args[1:])
|
||||||
|
if help {
|
||||||
|
fmt.Printf("Usage: %s [options]\n", os.Args[0])
|
||||||
|
goecsFlag.PrintDefaults()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
sig := make(chan os.Signal, 1)
|
||||||
|
signal.Notify(sig, os.Interrupt, syscall.SIGINT, syscall.SIGTERM)
|
||||||
if showVersion {
|
if showVersion {
|
||||||
fmt.Println(ecsVersion)
|
fmt.Println(ecsVersion)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
if enableLogger {
|
||||||
|
gostunmodel.EnableLoger = true
|
||||||
|
basicmodel.EnableLoger = true
|
||||||
|
cputestmodel.EnableLoger = true
|
||||||
|
memorytestmodel.EnableLoger = true
|
||||||
|
disktestmodel.EnableLoger = true
|
||||||
|
commediatests.EnableLoger = true
|
||||||
|
|
||||||
|
backtraceori.EnableLoger = true
|
||||||
|
|
||||||
|
speedtestmodel.EnableLoger = true
|
||||||
|
}
|
||||||
|
if menuMode {
|
||||||
|
basicStatus, cpuTestStatus, memoryTestStatus, diskTestStatus = false, false, false, false
|
||||||
|
commTestStatus, utTestStatus, securityTestStatus, emailTestStatus = false, false, false, false
|
||||||
|
backtraceStatus, nt3Status, speedTestStatus = false, false, false
|
||||||
|
switch language {
|
||||||
|
case "zh":
|
||||||
|
fmt.Println("VPS融合怪版本: ", ecsVersion)
|
||||||
|
fmt.Println("1. 融合怪完全体")
|
||||||
|
fmt.Println("2. 极简版(系统信息+CPU+内存+磁盘+测速节点5个)")
|
||||||
|
fmt.Println("3. 精简版(系统信息+CPU+内存+磁盘+御三家+常用流媒体+回程+路由+测速节点5个)")
|
||||||
|
fmt.Println("4. 精简网络版(系统信息+CPU+内存+磁盘+回程+路由+测速节点5个)")
|
||||||
|
fmt.Println("5. 精简解锁版(系统信息+CPU+内存+磁盘IO+御三家+常用流媒体+测速节点5个)")
|
||||||
|
fmt.Println("6. 网络单项(IP质量检测+三网回程+三网路由与延迟+测速节点11个)")
|
||||||
|
fmt.Println("7. 解锁单项(御三家解锁+常用流媒体解锁)")
|
||||||
|
fmt.Println("8. 硬件单项(基础系统信息+CPU+内存+dd磁盘测试+fio磁盘测试)")
|
||||||
|
fmt.Println("9. IP质量检测(15个数据库的IP检测+邮件端口检测)")
|
||||||
|
fmt.Println("10. 三网回程线路+广州三网路由+全国三网延迟")
|
||||||
|
case "en":
|
||||||
|
fmt.Println("VPS Fusion Monster Test Version: ", ecsVersion)
|
||||||
|
fmt.Println("1. VPS Fusion Monster Test Comprehensive Test Suite")
|
||||||
|
fmt.Println("2. Minimal Test Suite (System Info + CPU + Memory + Disk + 5 Speed Test Nodes)")
|
||||||
|
fmt.Println("3. Standard Test Suite (System Info + CPU + Memory + Disk + Basic Unlock Tests + Common Streaming Services + 5 Speed Test Nodes)")
|
||||||
|
fmt.Println("4. Network-Focused Test Suite (System Info + CPU + Memory + Disk + 5 Speed Test Nodes)")
|
||||||
|
fmt.Println("5. Unlock-Focused Test Suite (System Info + CPU + Memory + Disk IO + Basic Unlock Tests + Common Streaming Services + 5 Speed Test Nodes)")
|
||||||
|
fmt.Println("6. Network-Only Test (IP Quality Test + 5 Speed Test Nodes)")
|
||||||
|
fmt.Println("7. Unlock-Only Test (Basic Unlock Tests + Common Streaming Services Unlock)")
|
||||||
|
fmt.Println("8. Hardware-Only Test (Basic System Info + CPU + Memory + dd Disk Test + fio Disk Test)")
|
||||||
|
fmt.Println("9. IP Quality Test (IP Test with 15 Databases + Email Port Test)")
|
||||||
|
}
|
||||||
|
Loop:
|
||||||
|
for {
|
||||||
|
fmt.Print("请输入选项 / Please enter your choice: ")
|
||||||
|
fmt.Scanln(&input)
|
||||||
|
input = strings.TrimSpace(input)
|
||||||
|
input = strings.TrimRight(input, "\n")
|
||||||
|
re := regexp.MustCompile(`^\d+$`) // 正则表达式匹配纯数字
|
||||||
|
if re.MatchString(input) {
|
||||||
|
choice = input
|
||||||
|
switch choice {
|
||||||
|
case "1":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
commTestStatus = true
|
||||||
|
utTestStatus = true
|
||||||
|
securityTestStatus = true
|
||||||
|
emailTestStatus = true
|
||||||
|
backtraceStatus = true
|
||||||
|
nt3Status = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "2":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "3":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
commTestStatus = true
|
||||||
|
utTestStatus = true
|
||||||
|
securityTestStatus = true
|
||||||
|
backtraceStatus = true
|
||||||
|
nt3Status = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "4":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
backtraceStatus = true
|
||||||
|
nt3Status = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "5":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
securityTestStatus = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "6":
|
||||||
|
speedTestStatus = true
|
||||||
|
backtraceStatus = true
|
||||||
|
nt3Status = true
|
||||||
|
break Loop
|
||||||
|
case "7":
|
||||||
|
securityTestStatus = true
|
||||||
|
commTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "8":
|
||||||
|
basicStatus = true
|
||||||
|
cpuTestStatus = true
|
||||||
|
memoryTestStatus = true
|
||||||
|
diskTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "9":
|
||||||
|
emailTestStatus = true
|
||||||
|
break Loop
|
||||||
|
case "10":
|
||||||
|
backtraceStatus = true
|
||||||
|
nt3Status = true
|
||||||
|
speedTestStatus = true
|
||||||
|
break Loop
|
||||||
|
default:
|
||||||
|
if language == "zh" {
|
||||||
|
fmt.Println("无效的选项")
|
||||||
|
} else {
|
||||||
|
fmt.Println("Invalid choice")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if language == "zh" {
|
||||||
|
fmt.Println("输入错误,请输入一个纯数字")
|
||||||
|
} else {
|
||||||
|
fmt.Println("Invalid input, please enter a number")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if language == "en" {
|
||||||
|
backtraceStatus = false
|
||||||
|
nt3Status = false
|
||||||
|
}
|
||||||
startTime := time.Now()
|
startTime := time.Now()
|
||||||
var (
|
var (
|
||||||
wg sync.WaitGroup
|
wg1, wg2 sync.WaitGroup
|
||||||
basicInfo, securityInfo, emailInfo, mediaInfo string
|
basicInfo, securityInfo, emailInfo, mediaInfo string
|
||||||
output, tempOutput string
|
output, tempOutput string
|
||||||
)
|
)
|
||||||
output = utils.PrintAndCapture(func() {
|
// 启动一个goroutine来等待信号
|
||||||
switch language {
|
go func() {
|
||||||
case "zh":
|
// 等待信号
|
||||||
|
<-sig
|
||||||
|
utils.ProcessAndUpload(output, filePath, enabelUpload)
|
||||||
|
os.Exit(1) // 使用非零状态码退出,表示意外退出
|
||||||
|
}()
|
||||||
|
switch language {
|
||||||
|
case "zh":
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
utils.PrintHead(language, width, ecsVersion)
|
utils.PrintHead(language, width, ecsVersion)
|
||||||
utils.PrintCenteredTitle("基础信息", width)
|
if basicStatus || securityTestStatus {
|
||||||
basicInfo, securityInfo, nt3CheckType = utils.SecurityCheck(language, nt3CheckType)
|
if basicStatus {
|
||||||
fmt.Printf(basicInfo)
|
utils.PrintCenteredTitle("系统基础信息", width)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("CPU测试-通过%s测试", cpuTestMethod), width)
|
}
|
||||||
cputest.CpuTest(language, cpuTestMethod, cpuTestThreadMode)
|
basicInfo, securityInfo, nt3CheckType = utils.SecurityCheck(language, nt3CheckType, securityTestStatus)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("内存测试-通过%s测试", cpuTestMethod), width)
|
if basicStatus {
|
||||||
memorytest.MemoryTest(language, memoryTestMethod)
|
fmt.Printf(basicInfo)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("硬盘测试-通过%s测试", diskTestMethod), width)
|
}
|
||||||
disktest.DiskTest(language, diskTestMethod, diskTestPath, diskMultiCheck)
|
}
|
||||||
utils.PrintCenteredTitle("御三家流媒体解锁", width)
|
}, tempOutput, output)
|
||||||
wg.Add(2)
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if cpuTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("CPU测试-通过%s测试", cpuTestMethod), width)
|
||||||
|
cputest.CpuTest(language, cpuTestMethod, cpuTestThreadMode)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if memoryTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("内存测试-通过%s测试", cpuTestMethod), width)
|
||||||
|
memorytest.MemoryTest(language, memoryTestMethod)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if diskTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("硬盘测试-通过%s测试", diskTestMethod), width)
|
||||||
|
disktest.DiskTest(language, diskTestMethod, diskTestPath, diskMultiCheck)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
if emailTestStatus {
|
||||||
|
wg2.Add(1)
|
||||||
go func() {
|
go func() {
|
||||||
defer wg.Done()
|
defer wg2.Done()
|
||||||
emailInfo = email.EmailCheck()
|
emailInfo = email.EmailCheck()
|
||||||
}()
|
}()
|
||||||
|
}
|
||||||
|
if utTestStatus {
|
||||||
|
wg1.Add(1)
|
||||||
go func() {
|
go func() {
|
||||||
defer wg.Done()
|
defer wg1.Done()
|
||||||
mediaInfo = unlocktest.MediaTest(language)
|
mediaInfo = unlocktest.MediaTest(language)
|
||||||
}()
|
}()
|
||||||
commediatest.ComMediaTest(language)
|
}
|
||||||
utils.PrintCenteredTitle("跨国流媒体解锁", width)
|
output = utils.PrintAndCapture(func() {
|
||||||
wg.Wait() // 后台任务含流媒体测试和邮件测试
|
if commTestStatus {
|
||||||
fmt.Printf(mediaInfo)
|
utils.PrintCenteredTitle("御三家流媒体解锁", width)
|
||||||
utils.PrintCenteredTitle("IP质量检测", width)
|
commediatest.ComMediaTest(language)
|
||||||
fmt.Printf(securityInfo)
|
|
||||||
utils.PrintCenteredTitle("邮件端口检测", width)
|
|
||||||
fmt.Println(emailInfo)
|
|
||||||
if runtime.GOOS != "windows" {
|
|
||||||
utils.PrintCenteredTitle("三网回程", width)
|
|
||||||
backtrace.BackTrace()
|
|
||||||
// nexttrace 在win上不支持检测,报错 bind: An invalid argument was supplied.
|
|
||||||
utils.PrintCenteredTitle("路由检测", width)
|
|
||||||
ntrace.TraceRoute3(language, nt3Location, nt3CheckType)
|
|
||||||
}
|
}
|
||||||
utils.PrintCenteredTitle("就近节点测速", width)
|
}, tempOutput, output)
|
||||||
speedtest.ShowHead(language)
|
output = utils.PrintAndCapture(func() {
|
||||||
speedtest.NearbySP()
|
if utTestStatus {
|
||||||
speedtest.CustomSP("net", "global", 4)
|
utils.PrintCenteredTitle("跨国流媒体解锁", width)
|
||||||
speedtest.CustomSP("net", "cu", spNum)
|
wg1.Wait()
|
||||||
speedtest.CustomSP("net", "ct", spNum)
|
fmt.Printf(mediaInfo)
|
||||||
speedtest.CustomSP("net", "cmcc", spNum)
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if securityTestStatus {
|
||||||
|
utils.PrintCenteredTitle("IP质量检测", width)
|
||||||
|
fmt.Printf(securityInfo)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if emailTestStatus {
|
||||||
|
utils.PrintCenteredTitle("邮件端口检测", width)
|
||||||
|
wg2.Wait()
|
||||||
|
fmt.Println(emailInfo)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
if runtime.GOOS != "windows" {
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if backtraceStatus {
|
||||||
|
utils.PrintCenteredTitle("三网回程线路检测", width)
|
||||||
|
backtrace.BackTrace()
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
// nexttrace 在win上不支持检测,报错 bind: An invalid argument was supplied.
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if nt3Status {
|
||||||
|
utils.PrintCenteredTitle("三网回程路由检测", width)
|
||||||
|
ntrace.TraceRoute3(language, nt3Location, nt3CheckType)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
}
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if speedTestStatus {
|
||||||
|
utils.PrintCenteredTitle("就近节点测速", width)
|
||||||
|
speedtest.ShowHead(language)
|
||||||
|
if (menuMode && choice == "1") || !menuMode {
|
||||||
|
speedtest.NearbySP()
|
||||||
|
speedtest.CustomSP("net", "global", 2)
|
||||||
|
speedtest.CustomSP("net", "cu", spNum)
|
||||||
|
speedtest.CustomSP("net", "ct", spNum)
|
||||||
|
speedtest.CustomSP("net", "cmcc", spNum)
|
||||||
|
} else if menuMode && choice == "2" || choice == "3" || choice == "4" || choice == "5" {
|
||||||
|
speedtest.CustomSP("net", "global", 4)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
endTime := time.Now()
|
||||||
|
duration := endTime.Sub(startTime)
|
||||||
|
minutes := int(duration.Minutes())
|
||||||
|
seconds := int(duration.Seconds()) % 60
|
||||||
|
currentTime := time.Now().Format("Mon Jan 2 15:04:05 MST 2006")
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
utils.PrintCenteredTitle("", width)
|
utils.PrintCenteredTitle("", width)
|
||||||
endTime := time.Now()
|
|
||||||
duration := endTime.Sub(startTime)
|
|
||||||
minutes := int(duration.Minutes())
|
|
||||||
seconds := int(duration.Seconds()) % 60
|
|
||||||
currentTime := time.Now().Format("Mon Jan 2 15:04:05 MST 2006")
|
|
||||||
fmt.Printf("花费 : %d 分 %d 秒\n", minutes, seconds)
|
fmt.Printf("花费 : %d 分 %d 秒\n", minutes, seconds)
|
||||||
fmt.Printf("时间 : %s\n", currentTime)
|
fmt.Printf("时间 : %s\n", currentTime)
|
||||||
utils.PrintCenteredTitle("", width)
|
utils.PrintCenteredTitle("", width)
|
||||||
case "en":
|
}, tempOutput, output)
|
||||||
|
case "en":
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
utils.PrintHead(language, width, ecsVersion)
|
utils.PrintHead(language, width, ecsVersion)
|
||||||
utils.PrintCenteredTitle("Basic Information", width)
|
if basicStatus || securityTestStatus {
|
||||||
basicInfo, securityInfo, nt3CheckType = utils.SecurityCheck(language, nt3CheckType)
|
if basicStatus {
|
||||||
fmt.Printf(basicInfo)
|
utils.PrintCenteredTitle("System Basic Information", width)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("CPU Test - %s Method", cpuTestMethod), width)
|
}
|
||||||
cputest.CpuTest(language, cpuTestMethod, cpuTestThreadMode)
|
basicInfo, securityInfo, nt3CheckType = utils.SecurityCheck(language, nt3CheckType, securityTestStatus)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("Memory Test - %s Method", memoryTestMethod), width)
|
if basicStatus {
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("Disk Test - %s Method", diskTestMethod), width)
|
fmt.Printf(basicInfo)
|
||||||
utils.PrintCenteredTitle(fmt.Sprintf("Disk Test - %s Method", diskTestMethod), width)
|
}
|
||||||
disktest.DiskTest(language, diskTestMethod, diskTestPath, diskMultiCheck)
|
}
|
||||||
wg.Add(1)
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if cpuTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("CPU Test - %s Method", cpuTestMethod), width)
|
||||||
|
cputest.CpuTest(language, cpuTestMethod, cpuTestThreadMode)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if memoryTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("Memory Test - %s Method", memoryTestMethod), width)
|
||||||
|
memorytest.MemoryTest(language, memoryTestMethod)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if diskTestStatus {
|
||||||
|
utils.PrintCenteredTitle(fmt.Sprintf("Disk Test - %s Method", diskTestMethod), width)
|
||||||
|
disktest.DiskTest(language, diskTestMethod, diskTestPath, diskMultiCheck)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
if emailTestStatus {
|
||||||
|
wg1.Add(1)
|
||||||
go func() {
|
go func() {
|
||||||
defer wg.Done()
|
defer wg1.Done()
|
||||||
emailInfo = email.EmailCheck()
|
emailInfo = email.EmailCheck()
|
||||||
}()
|
}()
|
||||||
utils.PrintCenteredTitle("The Three Families Streaming Media Unlock", width)
|
}
|
||||||
commediatest.ComMediaTest(language)
|
output = utils.PrintAndCapture(func() {
|
||||||
utils.PrintCenteredTitle("Cross-Border Streaming Media Unlock", width)
|
if commTestStatus {
|
||||||
unlocktest.MediaTest(language)
|
utils.PrintCenteredTitle("The Three Main Streaming Media Unlock", width)
|
||||||
utils.PrintCenteredTitle("IP Quality Check", width)
|
commediatest.ComMediaTest(language)
|
||||||
fmt.Printf(securityInfo)
|
}
|
||||||
utils.PrintCenteredTitle("Email Port Check", width)
|
}, tempOutput, output)
|
||||||
wg.Wait()
|
output = utils.PrintAndCapture(func() {
|
||||||
fmt.Println(emailInfo)
|
if utTestStatus {
|
||||||
//utils.PrintCenteredTitle("Return Path Routing", width)
|
utils.PrintCenteredTitle("Cross-Border Streaming Media Unlock", width)
|
||||||
utils.PrintCenteredTitle("Nearby Node Speed Test", width)
|
unlocktest.MediaTest(language)
|
||||||
speedtest.ShowHead(language)
|
}
|
||||||
speedtest.NearbySP()
|
}, tempOutput, output)
|
||||||
speedtest.CustomSP("net", "global", -1)
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if securityTestStatus {
|
||||||
|
utils.PrintCenteredTitle("IP Quality Check", width)
|
||||||
|
fmt.Printf(securityInfo)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if emailTestStatus {
|
||||||
|
utils.PrintCenteredTitle("Email Port Check", width)
|
||||||
|
wg1.Wait()
|
||||||
|
fmt.Println(emailInfo)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
|
if speedTestStatus {
|
||||||
|
utils.PrintCenteredTitle("Nearby Node Speed Test", width)
|
||||||
|
speedtest.ShowHead(language)
|
||||||
|
speedtest.NearbySP()
|
||||||
|
speedtest.CustomSP("net", "global", -1)
|
||||||
|
}
|
||||||
|
}, tempOutput, output)
|
||||||
|
|
||||||
|
endTime := time.Now()
|
||||||
|
duration := endTime.Sub(startTime)
|
||||||
|
minutes := int(duration.Minutes())
|
||||||
|
seconds := int(duration.Seconds()) % 60
|
||||||
|
currentTime := time.Now().Format("Mon Jan 2 15:04:05 MST 2006")
|
||||||
|
output = utils.PrintAndCapture(func() {
|
||||||
utils.PrintCenteredTitle("", width)
|
utils.PrintCenteredTitle("", width)
|
||||||
endTime := time.Now()
|
|
||||||
duration := endTime.Sub(startTime)
|
|
||||||
minutes := int(duration.Minutes())
|
|
||||||
seconds := int(duration.Seconds()) % 60
|
|
||||||
currentTime := time.Now().Format("Mon Jan 2 15:04:05 MST 2006")
|
|
||||||
fmt.Printf("Cost Time : %d 分 %d 秒\n", minutes, seconds)
|
fmt.Printf("Cost Time : %d 分 %d 秒\n", minutes, seconds)
|
||||||
fmt.Printf("Current Time : %s\n", currentTime)
|
fmt.Printf("Current Time : %s\n", currentTime)
|
||||||
utils.PrintCenteredTitle("", width)
|
utils.PrintCenteredTitle("", width)
|
||||||
default:
|
}, tempOutput, output)
|
||||||
fmt.Println("Unsupported language")
|
default:
|
||||||
}
|
fmt.Println("Unsupported language")
|
||||||
}, tempOutput, output)
|
|
||||||
// 创建文件
|
|
||||||
filePath := "goecs.txt"
|
|
||||||
file, err := os.Create(filePath)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println("Can not make file:", err)
|
|
||||||
return
|
|
||||||
}
|
}
|
||||||
defer file.Close()
|
utils.ProcessAndUpload(output, filePath, enabelUpload)
|
||||||
// 将 output 写入文件
|
if runtime.GOOS == "windows" || runtime.GOOS == "darwin" {
|
||||||
// 匹配 ANSI 转义序列
|
fmt.Println("Press Enter to exit...")
|
||||||
ansiRegex := regexp.MustCompile("\x1B\\[[0-9;]+[a-zA-Z]")
|
fmt.Scanln()
|
||||||
// 移除 ANSI 转义序列
|
|
||||||
cleanedOutput := ansiRegex.ReplaceAllString(output, "")
|
|
||||||
_, err = file.WriteString(cleanedOutput)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println("Can not write file:", err)
|
|
||||||
return
|
|
||||||
}
|
}
|
||||||
// 获取文件的绝对路径
|
|
||||||
absPath, err := filepath.Abs(filePath)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println("Get file absPath failed:", err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
shorturl, err := utils.UploadText(absPath)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println("Upload failed, can not generate short URL.")
|
|
||||||
fmt.Println(err.Error())
|
|
||||||
}
|
|
||||||
fmt.Println("Upload successful, short URL:", shorturl)
|
|
||||||
}
|
}
|
||||||
|
56
goecs.sh
56
goecs.sh
@@ -59,17 +59,16 @@ goecs_check() {
|
|||||||
ECS_VERSION=$(curl -m 6 -sSL "https://githubapi.spiritlhl.top/repos/oneclickvirt/ecs/releases/latest" | awk -F \" '/tag_name/{gsub(/^v/,"",$4); print $4}')
|
ECS_VERSION=$(curl -m 6 -sSL "https://githubapi.spiritlhl.top/repos/oneclickvirt/ecs/releases/latest" | awk -F \" '/tag_name/{gsub(/^v/,"",$4); print $4}')
|
||||||
fi
|
fi
|
||||||
# 检测原始goecs命令是否存在,若存在则升级,不存在则安装
|
# 检测原始goecs命令是否存在,若存在则升级,不存在则安装
|
||||||
version_output=$(goecs -v || ./goecs -v)
|
version_output=$(goecs -v command 2>/dev/null || ./goecs -v command 2>/dev/null)
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
extracted_version=$(echo "$version_output" | grep -oP '^v\d+(\.\d+)+')
|
extracted_version=$(echo "${version_output//v/}")
|
||||||
if [ -n "$extracted_version" ]; then
|
if [ -n "$extracted_version" ]; then
|
||||||
current_version=$(echo "$extracted_version" | cut -c 2-)
|
|
||||||
ecs_version=$ECS_VERSION
|
ecs_version=$ECS_VERSION
|
||||||
if [[ "$(echo -e "$current_version\n$ecs_version" | sort -V | tail -n 1)" == "$current_version" ]]; then
|
if [[ "$(echo -e "$extracted_version\n$ecs_version" | sort -V | tail -n 1)" == "$extracted_version" ]]; then
|
||||||
echo "goecs version ($current_version) is latest, no need to upgrade."
|
echo "goecs version ($extracted_version) is latest, no need to upgrade."
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
echo "goecs version ($current_version) < $ecs_version, need to upgrade, 5 seconds later will start to upgrade"
|
echo "goecs version ($extracted_version) < $ecs_version, need to upgrade, 5 seconds later will start to upgrade"
|
||||||
rm -rf /usr/bin/goecs
|
rm -rf /usr/bin/goecs
|
||||||
rm -rf goecs
|
rm -rf goecs
|
||||||
fi
|
fi
|
||||||
@@ -163,7 +162,7 @@ InstallSysbench() {
|
|||||||
arch) pacman -S --needed --noconfirm sysbench && pacman -S --needed --noconfirm libaio && ldconfig ;;
|
arch) pacman -S --needed --noconfirm sysbench && pacman -S --needed --noconfirm libaio && ldconfig ;;
|
||||||
freebsd) pkg install -y sysbench ;;
|
freebsd) pkg install -y sysbench ;;
|
||||||
alpinelinux) echo -e "${Msg_Warning}Sysbench Module not found, installing ..." && echo -e "${Msg_Warning}SysBench Current not support Alpine Linux, Skipping..." && Var_Skip_SysBench="1" ;;
|
alpinelinux) echo -e "${Msg_Warning}Sysbench Module not found, installing ..." && echo -e "${Msg_Warning}SysBench Current not support Alpine Linux, Skipping..." && Var_Skip_SysBench="1" ;;
|
||||||
*) echo "Error: Unknown OS release: $os_release" && exit 1 ;;
|
*) echo "Error: Unknown OS release: $os_release" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -230,7 +229,7 @@ prepare_compile_env() {
|
|||||||
env_check() {
|
env_check() {
|
||||||
REGEX=("debian|astra" "ubuntu" "centos|red hat|kernel|oracle linux|alma|rocky" "'amazon linux'" "fedora" "arch" "freebsd" "alpine" "openbsd")
|
REGEX=("debian|astra" "ubuntu" "centos|red hat|kernel|oracle linux|alma|rocky" "'amazon linux'" "fedora" "arch" "freebsd" "alpine" "openbsd")
|
||||||
RELEASE=("Debian" "Ubuntu" "CentOS" "CentOS" "Fedora" "Arch" "FreeBSD" "Alpine" "OpenBSD")
|
RELEASE=("Debian" "Ubuntu" "CentOS" "CentOS" "Fedora" "Arch" "FreeBSD" "Alpine" "OpenBSD")
|
||||||
PACKAGE_UPDATE=("! apt-get update && apt-get --fix-broken install -y && apt-get update" "apt-get update" "yum -y update" "yum -y update" "yum -y update" "pacman -Sy" "pkg update" "apk update" "pkg_add -u")
|
PACKAGE_UPDATE=("apt-get update" "apt-get update" "yum -y update" "yum -y update" "yum -y update" "pacman -Sy" "pkg update" "apk update" "pkg_add -u")
|
||||||
PACKAGE_INSTALL=("apt-get -y install" "apt-get -y install" "yum -y install" "yum -y install" "yum -y install" "pacman -Sy --noconfirm --needed" "pkg install -y" "apk add")
|
PACKAGE_INSTALL=("apt-get -y install" "apt-get -y install" "yum -y install" "yum -y install" "yum -y install" "pacman -Sy --noconfirm --needed" "pkg install -y" "apk add")
|
||||||
PACKAGE_REMOVE=("apt-get -y remove" "apt-get -y remove" "yum -y remove" "yum -y remove" "yum -y remove" "pacman -Rsc --noconfirm" "pkg delete" "apk del")
|
PACKAGE_REMOVE=("apt-get -y remove" "apt-get -y remove" "yum -y remove" "yum -y remove" "yum -y remove" "pacman -Rsc --noconfirm" "pkg delete" "apk del")
|
||||||
PACKAGE_UNINSTALL=("apt-get -y autoremove" "apt-get -y autoremove" "yum -y autoremove" "yum -y autoremove" "yum -y autoremove" "" "pkg autoremove" "apk autoremove")
|
PACKAGE_UNINSTALL=("apt-get -y autoremove" "apt-get -y autoremove" "yum -y autoremove" "yum -y autoremove" "yum -y autoremove" "" "pkg autoremove" "apk autoremove")
|
||||||
@@ -245,6 +244,16 @@ env_check() {
|
|||||||
done
|
done
|
||||||
cdn_urls=("https://cdn0.spiritlhl.top/" "http://cdn3.spiritlhl.net/" "http://cdn1.spiritlhl.net/" "http://cdn2.spiritlhl.net/")
|
cdn_urls=("https://cdn0.spiritlhl.top/" "http://cdn3.spiritlhl.net/" "http://cdn1.spiritlhl.net/" "http://cdn2.spiritlhl.net/")
|
||||||
check_cdn_file
|
check_cdn_file
|
||||||
|
_green "Update system manager."
|
||||||
|
$PACKAGE_UPDATE command 2>/dev/null
|
||||||
|
if ! command -v tar >/dev/null 2>&1; then
|
||||||
|
_green "Installing tar"
|
||||||
|
$PACKAGE_INSTALL tar
|
||||||
|
fi
|
||||||
|
if ! command -v unzip >/dev/null 2>&1; then
|
||||||
|
_green "Installing unzip"
|
||||||
|
$PACKAGE_INSTALL unzip
|
||||||
|
fi
|
||||||
if ! command -v dd >/dev/null 2>&1; then
|
if ! command -v dd >/dev/null 2>&1; then
|
||||||
_green "Installing dd"
|
_green "Installing dd"
|
||||||
$PACKAGE_INSTALL dd
|
$PACKAGE_INSTALL dd
|
||||||
@@ -291,16 +300,36 @@ env_check() {
|
|||||||
echo "rm -rf /usr/bin/speedtest-go"
|
echo "rm -rf /usr/bin/speedtest-go"
|
||||||
_blue "to uninstall speedtest and speedtest-go"
|
_blue "to uninstall speedtest and speedtest-go"
|
||||||
fi
|
fi
|
||||||
|
if [ "$(uname -s)" = "Darwin" ]; then
|
||||||
|
echo "Detected MacOS. Installing sysbench and fio..."
|
||||||
|
brew install --force sysbench fio dd
|
||||||
|
# 有问题,需要修复,root环境不能brew,brew安装完毕后可能路径不在环境变量中
|
||||||
|
fi
|
||||||
|
_green "The environment is ready."
|
||||||
|
}
|
||||||
|
|
||||||
|
delete_goecs() {
|
||||||
|
rm -rf /root/goecs
|
||||||
|
rm -rf /usr/bin/goecs
|
||||||
}
|
}
|
||||||
|
|
||||||
show_help() {
|
show_help() {
|
||||||
cat <<"EOF"
|
cat <<"EOF"
|
||||||
Available commands:
|
Available commands:
|
||||||
|
|
||||||
env Check and Install package: dd fio sysbench geekbench5 speedtest
|
./goecs.sh env Check and Install package:
|
||||||
install Install goecs command
|
tar (Almost all unix-like systems have it.)
|
||||||
upgrade Upgrade goecs command
|
unzip (Almost all unix-like systems have it.)
|
||||||
help Show this message
|
dd (Almost all unix-like systems have it.)
|
||||||
|
fio (Almost all unix-like systems can be installed through the system's package manager.)
|
||||||
|
sysbench (Almost all unix-like systems can be installed through the system's package manager.)
|
||||||
|
geekbench (geekbench5)(Only support IPV4 environment, and memory greater than 1GB network detection, only support amd64 and arm64 architecture.)
|
||||||
|
speedtest (Use the officially provided binaries for more accurate test results.)
|
||||||
|
In fact, sysbench/geekbench is the only one of the above dependencies that must be installed, without which the CPU score cannot be tested.
|
||||||
|
./goecs.sh install Install goecs command
|
||||||
|
./goecs.sh upgrade Upgrade goecs command
|
||||||
|
./goecs.sh delete Uninstall goecs command
|
||||||
|
./goecs.sh help Show this message
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
}
|
}
|
||||||
@@ -315,6 +344,9 @@ case "$1" in
|
|||||||
"install" | "upgrade")
|
"install" | "upgrade")
|
||||||
goecs_check
|
goecs_check
|
||||||
;;
|
;;
|
||||||
|
"delete")
|
||||||
|
delete_goecs
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
echo "No command found."
|
echo "No command found."
|
||||||
echo
|
echo
|
||||||
|
108
goecs.txt
108
goecs.txt
@@ -1,108 +0,0 @@
|
|||||||
---------------------------------------融合怪测试----------------------------------------
|
|
||||||
版本:2024.06.30
|
|
||||||
测评频道: https://t.me/vps_reviews
|
|
||||||
Go项目地址:https://github.com/oneclickvirt/ecs
|
|
||||||
Shell项目地址:https://github.com/spiritLHLS/ecs
|
|
||||||
----------------------------------------基础信息----------------------------------------
|
|
||||||
CPU 型号 : AMD Ryzen 7 4700U with Radeon Graphics
|
|
||||||
CPU 数量 : 8 Physical CPU(s)
|
|
||||||
CPU 缓存 : L1: null / L2: 4.00 MB / L3: 8.00 MB
|
|
||||||
VM-x/AMD-V/Hyper-V : ❌ Disabled
|
|
||||||
内存 : 10.90 GB / 15.37 GB
|
|
||||||
Swap : 16.23 GB / 22.12 GB
|
|
||||||
硬盘空间 : 213.82 GB / 475.67 GB
|
|
||||||
启动盘路径 : C:
|
|
||||||
系统 : Microsoft Windows 11 Enterprise 10.0.22631 Build 22631 [x86_64]
|
|
||||||
系统在线时间 : 5 days, 02 hours, 41 minutes
|
|
||||||
时区 : (UTC+08:00) 北京,重庆,香港特别行政区,乌鲁木齐
|
|
||||||
负载 : 0.50 / 0.00 / 0.00
|
|
||||||
虚拟化架构 : Physical-Machine(Multiprocessor Free)
|
|
||||||
NAT类型 : Symmetric
|
|
||||||
IPV4 ASN : AS4538 China Education and Research Network Center
|
|
||||||
IPV4 Location : Guangzhou / Guangdong / China
|
|
||||||
IPV6 ASN : AS24357 CERNET2 IX at South China University of Technology
|
|
||||||
IPV6 Location : Guangzhou / Guangdong / China
|
|
||||||
---------------------------------CPU测试-通过sysbench测试---------------------------------
|
|
||||||
Detected host is Windows, using Winsat for testing.
|
|
||||||
CPU AES256 加密: 7421.91MB/s
|
|
||||||
CPU LZW 压缩: 664.76MB/s
|
|
||||||
---------------------------------内存测试-通过sysbench测试----------------------------------
|
|
||||||
Detected host is Windows, using Winsat for testing.
|
|
||||||
内存性能: 31643.60MB/s
|
|
||||||
------------------------------------硬盘测试-通过fio测试------------------------------------
|
|
||||||
测试的硬盘 随机写入[得分] 顺序读取[得分] 顺序写入[得分]
|
|
||||||
C: 202.43 MB/s[7.8] 2212.48 MB/s[9.1] 1709.12 MB/s[8.9]
|
|
||||||
--------------------------------------御三家流媒体解锁--------------------------------------
|
|
||||||
[37m[01m----------------Netflix-----------------
|
|
||||||
[0m[32m[01m[IPV4][0m
|
|
||||||
[33m[01mNetflix在您的出口IP所在的国家不提供服务[0m
|
|
||||||
[32m[01m[IPV6][0m
|
|
||||||
[33m[01m您的网络可能没有正常配置IPv6,或者没有IPv6网络接入[0m
|
|
||||||
[37m[01m----------------Youtube-----------------
|
|
||||||
[0m[32m[01m[IPV4][0m
|
|
||||||
[33m[01mYoutube在您的出口IP所在的国家不提供服务[0m
|
|
||||||
[32m[01m[IPV6][0m
|
|
||||||
[33m[01mYoutube在您的出口IP所在的国家不提供服务[0m
|
|
||||||
[37m[01m---------------DisneyPlus---------------
|
|
||||||
[0m[32m[01m[IPV4][0m
|
|
||||||
[36m[01m当前IPv4出口所在地区即将开通DisneyPlus[0m
|
|
||||||
[32m[01m[IPV6][0m
|
|
||||||
[33m[01mDisneyPlus在您的出口IP所在的国家不提供服务[0m
|
|
||||||
--------------------------------------跨国流媒体解锁---------------------------------------
|
|
||||||
[36m[01mIPV4:[0m
|
|
||||||
============[ 跨国平台 ]============
|
|
||||||
Dazn [31m[01mNO[0m[31m[01m (UNSUPPORTED_COUNTRY)[0m
|
|
||||||
Disney+ [31m[01mNO[0m[31m[01m (Can not get assertion)[0m
|
|
||||||
Netflix [31m[01mBanned[0m
|
|
||||||
Netflix CDN [31m[01mNO[0m[31m[01m (IP Banned By Netflix)[0m
|
|
||||||
YouTube Region [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
YouTube CDN [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
Amazon Prime Video [31m[01mNO[0m[31m[01m (Region: CN)[0m
|
|
||||||
Paramount+ [32m[01mYES[0m[32m[01m [Via DNS][0m
|
|
||||||
TVBAnywhere+ [31m[01mNO[0m
|
|
||||||
IQiYi [32m[01mYES[0m[32m[01m (Region: CN)[0m[32m[01m [Via DNS][0m
|
|
||||||
Viu.com [32m[01mYES[0m[32m[01m [Via DNS][0m
|
|
||||||
Spotify Registration [31m[01mNO[0m
|
|
||||||
Steam Store [32m[01mYES[0m[32m[01m (Community Unavailable)[0m[32m[01m (Region: CN)[0m
|
|
||||||
ChatGPT [31m[01mNO[0m
|
|
||||||
Wikipedia Editability [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
TikTok [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
Bing Region [32m[01mYES[0m[32m[01m (Only cn.bing.com)[0m[32m[01m (Region: CN)[0m
|
|
||||||
Instagram Licensed Audio [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
KOCOWA [31m[01mNO[0m
|
|
||||||
SonyLiv [31m[01mNO[0m
|
|
||||||
OneTrust [32m[01mYES[0m[32m[01m (Region: CN GUANGDONG)[0m[32m[01m [Via DNS][0m
|
|
||||||
GoogleSearch [31m[01mNO[0m[33m[01m (Network Err)[0m
|
|
||||||
---------------------------------------IP质量检测---------------------------------------
|
|
||||||
---------------------------------------邮件端口检测---------------------------------------
|
|
||||||
Platform SMTP SMTPS POP3 POP3S IMAP IMAPS
|
|
||||||
LocalPort ✔ ✔ ✔ ✔ ✔ ✔
|
|
||||||
QQ ✔ ✔ ✔ ✘ ✔ ✘
|
|
||||||
163 ✔ ✔ ✔ ✘ ✔ ✘
|
|
||||||
Sohu ✔ ✔ ✘ ✘ ✔ ✘
|
|
||||||
Yandex ✔ ✔ ✔ ✘ ✔ ✘
|
|
||||||
Gmail ✘ ✘ ✘ ✘ ✘ ✘
|
|
||||||
Outlook ✔ ✘ ✔ ✘ ✔ ✘
|
|
||||||
Office365 ✔ ✘ ✔ ✘ ✔ ✘
|
|
||||||
Yahoo ✔ ✔ ✘ ✘ ✘ ✘
|
|
||||||
MailCOM ✔ ✔ ✔ ✘ ✔ ✘
|
|
||||||
MailRU ✔ ✔ ✘ ✘ ✔ ✘
|
|
||||||
AOL ✔ ✔ ✘ ✘ ✘ ✘
|
|
||||||
GMX ✔ ✘ ✔ ✘ ✔ ✘
|
|
||||||
Sina ✔ ✘ ✔ ✘ ✔ ✘
|
|
||||||
---------------------------------------就近节点测速---------------------------------------
|
|
||||||
位置 上传速度 下载速度 延迟 丢包率
|
|
||||||
Speedtest.net 4.32 Mbps 3.54 Mbps 12.205264ms 0.00% (Sent: 402/Dup: 0/Max: 401)
|
|
||||||
新加坡 18.50 Mbps 23.82 Mbps 51.944512ms N/A
|
|
||||||
洛杉矶 19.51 Mbps 8.51 Mbps 184.661804ms N/A
|
|
||||||
日本东京 1.47 Mbps 24.63 Mbps 201.89396ms N/A
|
|
||||||
法兰克福 19.22 Mbps 23.59 Mbps 245.545712ms N/A
|
|
||||||
联通Wu Xi -0.00 Mbps -0.00 Mbps 1s N/A
|
|
||||||
电信合肥5G 19.00 Mbps 24.51 Mbps 24.894272ms N/A
|
|
||||||
电信浙江 18.60 Mbps 23.93 Mbps 25.354408ms N/A
|
|
||||||
移动杭州5G 0.08 Mbps 23.74 Mbps 29.578304ms N/A
|
|
||||||
移动Beijing 18.70 Mbps 23.71 Mbps 40.95098ms N/A
|
|
||||||
------------------------------------------------------------------------------------
|
|
||||||
花费 : 7 分 53 秒
|
|
||||||
时间 : Sun Jun 30 20:47:15 CST 2024
|
|
||||||
------------------------------------------------------------------------------------
|
|
@@ -9,8 +9,11 @@ import (
|
|||||||
"github.com/oneclickvirt/security/network"
|
"github.com/oneclickvirt/security/network"
|
||||||
"io"
|
"io"
|
||||||
"os"
|
"os"
|
||||||
|
"path/filepath"
|
||||||
|
"regexp"
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
|
"time"
|
||||||
"unicode/utf8"
|
"unicode/utf8"
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -27,13 +30,13 @@ func PrintCenteredTitle(title string, width int) {
|
|||||||
// PrintHead 根据语言打印头部信息
|
// PrintHead 根据语言打印头部信息
|
||||||
func PrintHead(language string, width int, ecsVersion string) {
|
func PrintHead(language string, width int, ecsVersion string) {
|
||||||
if language == "zh" {
|
if language == "zh" {
|
||||||
PrintCenteredTitle("融合怪测试", width)
|
PrintCenteredTitle("VPS融合怪测试", width)
|
||||||
fmt.Printf("版本:%s\n", ecsVersion)
|
fmt.Printf("版本:%s\n", ecsVersion)
|
||||||
fmt.Println("测评频道: https://t.me/vps_reviews\n" +
|
fmt.Println("测评频道: https://t.me/vps_reviews\n" +
|
||||||
"Go项目地址:https://github.com/oneclickvirt/ecs\n" +
|
"Go项目地址:https://github.com/oneclickvirt/ecs\n" +
|
||||||
"Shell项目地址:https://github.com/spiritLHLS/ecs")
|
"Shell项目地址:https://github.com/spiritLHLS/ecs")
|
||||||
} else {
|
} else {
|
||||||
PrintCenteredTitle("Fusion Monster Test", width)
|
PrintCenteredTitle("VPS Fusion Monster Test", width)
|
||||||
fmt.Printf("Version: %s\n", ecsVersion)
|
fmt.Printf("Version: %s\n", ecsVersion)
|
||||||
fmt.Println("Review Channel: https://t.me/vps_reviews\n" +
|
fmt.Println("Review Channel: https://t.me/vps_reviews\n" +
|
||||||
"Go Project URL: https://github.com/oneclickvirt/ecs\n" +
|
"Go Project URL: https://github.com/oneclickvirt/ecs\n" +
|
||||||
@@ -42,14 +45,14 @@ func PrintHead(language string, width int, ecsVersion string) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// SecurityCheck 执行安全检查
|
// SecurityCheck 执行安全检查
|
||||||
func SecurityCheck(language, nt3CheckType string) (string, string, string) {
|
func SecurityCheck(language, nt3CheckType string, securtyCheckStatus bool) (string, string, string) {
|
||||||
var wgt sync.WaitGroup
|
var wgt sync.WaitGroup
|
||||||
var ipInfo, securityInfo, systemInfo string
|
var ipInfo, securityInfo, systemInfo string
|
||||||
var err error
|
var err error
|
||||||
wgt.Add(2)
|
wgt.Add(2)
|
||||||
go func() {
|
go func() {
|
||||||
defer wgt.Done()
|
defer wgt.Done()
|
||||||
ipInfo, securityInfo, err = network.NetworkCheck("both", true, language)
|
ipInfo, securityInfo, err = network.NetworkCheck("both", securtyCheckStatus, language)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println(err.Error())
|
fmt.Println(err.Error())
|
||||||
}
|
}
|
||||||
@@ -88,7 +91,7 @@ func SecurityCheck(language, nt3CheckType string) (string, string, string) {
|
|||||||
return basicInfo, securityInfo, nt3CheckType
|
return basicInfo, securityInfo, nt3CheckType
|
||||||
}
|
}
|
||||||
|
|
||||||
// CaptureOutput 捕获函数输出和错误输出并返回字符串
|
// CaptureOutput 捕获函数输出和错误输出,实时输出,并返回字符串
|
||||||
func CaptureOutput(f func()) string {
|
func CaptureOutput(f func()) string {
|
||||||
// 保存旧的 stdout 和 stderr
|
// 保存旧的 stdout 和 stderr
|
||||||
oldStdout := os.Stdout
|
oldStdout := os.Stdout
|
||||||
@@ -155,6 +158,11 @@ func UploadText(absPath string) (string, error) {
|
|||||||
url := "https://paste.spiritlhl.net/api/upload"
|
url := "https://paste.spiritlhl.net/api/upload"
|
||||||
token := network.SecurityUploadToken
|
token := network.SecurityUploadToken
|
||||||
client := req.DefaultClient()
|
client := req.DefaultClient()
|
||||||
|
client.SetTimeout(6 * time.Second)
|
||||||
|
client.R().
|
||||||
|
SetRetryCount(2).
|
||||||
|
SetRetryBackoffInterval(1*time.Second, 5*time.Second).
|
||||||
|
SetRetryFixedInterval(2 * time.Second)
|
||||||
file, _ := os.Open(absPath)
|
file, _ := os.Open(absPath)
|
||||||
resp, err := client.R().
|
resp, err := client.R().
|
||||||
SetHeader("Authorization", token).
|
SetHeader("Authorization", token).
|
||||||
@@ -174,3 +182,51 @@ func UploadText(absPath string) (string, error) {
|
|||||||
return "", fmt.Errorf("upload failed with status code: %d", resp.StatusCode)
|
return "", fmt.Errorf("upload failed with status code: %d", resp.StatusCode)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ProcessAndUpload 创建结果文件并上传文件
|
||||||
|
func ProcessAndUpload(output string, filePath string, enableUplaod bool) {
|
||||||
|
// 检查文件是否存在
|
||||||
|
if _, err := os.Stat(filePath); err == nil {
|
||||||
|
// 文件存在,删除文件
|
||||||
|
err = os.Remove(filePath)
|
||||||
|
if err != nil {
|
||||||
|
fmt.Println("Cannot delete file:", err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 创建文件
|
||||||
|
file, err := os.Create(filePath)
|
||||||
|
if err != nil {
|
||||||
|
fmt.Println("Cannot create file:", err)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
defer file.Close()
|
||||||
|
// 匹配 ANSI 转义序列
|
||||||
|
ansiRegex := regexp.MustCompile("\x1B\\[[0-9;]+[a-zA-Z]")
|
||||||
|
// 移除 ANSI 转义序列
|
||||||
|
cleanedOutput := ansiRegex.ReplaceAllString(output, "")
|
||||||
|
// 写入文件
|
||||||
|
_, err = file.WriteString(cleanedOutput)
|
||||||
|
if err != nil {
|
||||||
|
fmt.Println("Cannot write to file:", err)
|
||||||
|
return
|
||||||
|
} else {
|
||||||
|
fmt.Println("Write test result in ", filePath)
|
||||||
|
}
|
||||||
|
if enableUplaod {
|
||||||
|
// 获取文件的绝对路径
|
||||||
|
absPath, err2 := filepath.Abs(filePath)
|
||||||
|
if err2 != nil {
|
||||||
|
fmt.Println("Failed to get absolute file path:", err2)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
// 上传文件并生成短链接
|
||||||
|
shorturl, err3 := UploadText(absPath)
|
||||||
|
if err3 != nil {
|
||||||
|
fmt.Println("Upload failed, cannot generate short URL.")
|
||||||
|
fmt.Println(err3.Error())
|
||||||
|
return
|
||||||
|
}
|
||||||
|
fmt.Println("Upload successful, short URL:", shorturl)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
1
发布版本.bat
1
发布版本.bat
@@ -24,6 +24,7 @@ REM 提示用户输入版本号
|
|||||||
set /p version="Enter the version number (e.g., v1.0.0): "
|
set /p version="Enter the version number (e.g., v1.0.0): "
|
||||||
|
|
||||||
REM 创建并推送标签
|
REM 创建并推送标签
|
||||||
|
:push_tag
|
||||||
git tag %version%
|
git tag %version%
|
||||||
git push origin %version%
|
git push origin %version%
|
||||||
if errorlevel 1 (
|
if errorlevel 1 (
|
||||||
|
Reference in New Issue
Block a user