File tree 2 files changed +48
-0
lines changed
2 files changed +48
-0
lines changed Original file line number Diff line number Diff line change
1
+ # sockfwd
2
+
3
+ Forward data between sockets.
4
+
5
+ i.e. sockfwd can export unix socket via tcp port, and can export tcp socket which listen 127.0.0.1 via 0.0.0.0 host.
6
+
7
+ ## Usage
8
+
9
+ ```
10
+ Usage:
11
+ sockfwd [flags]
12
+
13
+ Flags:
14
+ -d, --destination string destination address, data will send to this address.
15
+ -s, --source string source address, which will accept connection at this address.
16
+ -q, --quiet quiet mode.
17
+ ```
18
+
19
+ ## Example
20
+
21
+ Export local docker to network:` ./sockfwd -s tcp://127.0.0.1:8090 -d unix:///var/run/docker.sock ` .
22
+
23
+ Export ` 127.0.0.1:8080 ` to ` 0.0.0.0:8090 ` : ` ./sockfwd -s tcp://127.0.0.1:8090 -d unix://127.0.0.1:8090 ` .
Original file line number Diff line number Diff line change
1
+ [ English Document] ( ./README.en.md )
2
+
3
+ # sockfwd
4
+
5
+ 一个在socket之间转发数据的小工具。
6
+
7
+ 比如,能够将unix socket通过tcp端口暴露出来,也可以将监听本地的tcp端口通过0.0.0.0暴露出来。
8
+
9
+ ## 用法
10
+
11
+ ```
12
+ Usage:
13
+ sockfwd [flags]
14
+
15
+ Flags:
16
+ -d, --destination string 目的地址,即要转发到的地址
17
+ -s, --source string 源地址,即接收请求的地址
18
+ -q, --quiet 静默模式
19
+ ```
20
+
21
+ ## 例子
22
+
23
+ 将本地的docker实例暴露到网络上:` ./sockfwd -s tcp://127.0.0.1:8090 -d unix:///var/run/docker.sock `
24
+
25
+ 将` 127.0.0.1:8080 ` 端口暴露到` 0.0.0.0:8090 ` 端口上:` ./sockfwd -s tcp://127.0.0.1:8090 -d unix://127.0.0.1:8090 `
You can’t perform that action at this time.
0 commit comments