我正在寻找http "tee“命令/servlet/{python,perl}-script。
基本上,我想将http post请求分发到多台机器上。一台机器或进程位于一个端口上,它接收http请求,然后以相同的格式将其发送给许多其他机器。下游服务器的响应可以忽略,http tee将始终返回HTTP_OK,没有输出...
这听起来很简单,它应该已经存在了。是吗?
发布于 2013-01-09 20:34:48
可以通过使用nc来创建http tee的慢速版本。
mknod backpipe p
while [[ true ]] ; do (nc -l YOUR_MAIN_PORT 0<backpipe | tee >( cat > /dev/tcp/YOUR_TEE_HOST/PORT ) | nc YOUR_BACKEND_HOST YOUR_BACKEND_PORT | tee -a outflow 1>backpipe); donehttps://stackoverflow.com/questions/12433448
复制相似问题