Use Proxy For websockets #29
Unanswered
sdoshidensity
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
How can we use proxy for websockets?
url1, err := url.Parse("http://dummy.com") // proxy url
fmt.Println(url1, err)
fialer := websocket.DefaultDialer
fialer.Proxy = transport.ProxyURL(url1)
con, res, err := fialer.Dial(m.wsEndpoint, nil)
if err != nil {
fmt.Println(err, "====================================", res)
return err
}
Beta Was this translation helpful? Give feedback.
All reactions