mirror of
				https://github.com/lwch/natpass
				synced 2025-10-31 23:32:32 +08:00 
			
		
		
		
	移除反向代理代码
This commit is contained in:
		
							
								
								
									
										20
									
								
								code/client/rule/vnc/worker.go
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								code/client/rule/vnc/worker.go
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,20 @@ | ||||
| package vnc | ||||
|  | ||||
| import ( | ||||
| 	"fmt" | ||||
| 	"natpass/code/client/rule/vnc/worker" | ||||
|  | ||||
| 	"github.com/gorilla/websocket" | ||||
| 	"github.com/lwch/runtime" | ||||
| ) | ||||
|  | ||||
| // RunWorker run vnc worker | ||||
| func RunWorker(port uint16, cursor bool) { | ||||
| 	worker := worker.NewWorker(cursor) | ||||
| 	if worker == nil { | ||||
| 		panic("build context failed") | ||||
| 	} | ||||
| 	conn, _, err := websocket.DefaultDialer.Dial(fmt.Sprintf("ws://127.0.0.1:%d", port), nil) | ||||
| 	runtime.Assert(err) | ||||
| 	worker.Do(conn) | ||||
| } | ||||
		Reference in New Issue
	
	Block a user
	 lwch
					lwch