8 Star 41 Fork 9

anolis / tone-agent

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

ToneAgent

standard-readme compliant

ToneAgent 是 T-One 运行用例的物理机器代理

ToneAgent 实现了多台机器和 T-One 之间的通讯, 保证 T-One 中用例的分布式执行, 提高执行效率。

通过 ToneAgent, T-One 可以向多台物理机/虚拟机分配待执行状态的用例。当用例完成后, T-One 会将不同机器的执行结果进行汇总, 并将结果展示在 T-One 平台上。

安装说明

前置条件

Go版本不低于1.15

安装

  • 克隆当前仓库
git clone git@gitee.com:anolis/tone-agent.git
  • 编译ToneAgent二进制
cd tone-agent
go build 
# or
go install ./...

如果你是用的是unix类的机器,可以直接执行当前目录的脚本start.sh

chmod +x start.sh
./start.sh

使用说明

配置文件

执行 ToneAgent 依赖配置文件 config.yaml

ToneAgent 二进制会默认在 当前目录 .用户目录 $HOME/toneagent 查找 配置文件 config.yaml

config.yaml 样例:

beego:  # beego相关配置文件
  AppName: toneagent
  RunMode: dev
  StaticDir: down1
  DirectoryIndex: true
  HttpAddr: 0.0.0.0
  CopyRequestBody: true
  HttpPort: 8479

result: # ToneAgent相关结果文件目录, 默认放在当前目录下
  ResultFileDir: results
  WaitingSyncResultDir: sync_results
  TmpScriptFileDir: scripts
  LogFileDir: logs
  LogFileName: toneagent.log

mode: active # ToneAgent模式
tsn: tone20210101-001 # ToneAgent标识
proxy: https://tone-agent.openanolis.cn # T-One代理地址

可以通过 export TONE_AGENT_PATH = $PATH 来修改 ToneAgent 的结果文件地址

主动模式

场景

适用于部署 Agent 的机器位于 NAT 之后,无法通过公网 IP 直接进行访问

通过在 config.yaml 中配置T-One的代理设置, 让部署 ToneAgent 的相关机器主动连接 T-One代理, 从而让相关机器能 PULL 任务、PUSH 任务和执行任务。

T-One 代理设置: proxy: https://tone-agent.openanolis.cn

被动模式

场景

适用于 T-One 代理位于 NAT 之后, 无法通过公网 IP 直接进行访问

T-One的代理端会向部署 ToneAgent 的相关机器推送任务, 从而让相关机器能执行任务。

贡献

欢迎加入。

创建一个issue!

License

Mulan

空文件

简介

暂无描述 展开 收起
Go 等 2 种语言
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Go
1
https://gitee.com/anolis/tone-agent.git
git@gitee.com:anolis/tone-agent.git
anolis
tone-agent
tone-agent
master

搜索帮助