pingap icon indicating copy to clipboard operation
pingap copied to clipboard

Do you have plan to add websocket proxy support?

Open Akagi201 opened this issue 1 year ago • 2 comments

I am not sure if websocket can be easily supported

Akagi201 avatar Apr 29 '24 02:04 Akagi201

Pingora supports gRPC and websocket proxying, athough I haven't used websocket proxy, but I think it should be usable.

vicanso avatar Apr 29 '24 11:04 vicanso

In web3 area, the most use cases are http and websocket rpcs. I am not sure whether websocket proxy can reuse the most logic(code) of http.

Akagi201 avatar May 03 '24 14:05 Akagi201

This question has been stale for a week. It will be closed in an additional day if not updated.

github-actions[bot] avatar Jun 04 '24 02:06 github-actions[bot]

This issue has been closed because it has been stalled with no activity.

github-actions[bot] avatar Jun 06 '24 02:06 github-actions[bot]

Is there any further update on this?

Hareramrai avatar Jun 27 '24 11:06 Hareramrai

Is there any problem with the websocket proxy??

vicanso avatar Jun 27 '24 12:06 vicanso

Is there any problem with the WebSocket proxy??

I wasn't able to find any documentation regarding the WebSocket. Does it support out-of-the-box?

Hareramrai avatar Jun 27 '24 13:06 Hareramrai

Yes, you can configure it through the admin web page or toml file. I will provide document later, may be version 0.6.0

vicanso avatar Jun 27 '24 13:06 vicanso

It would be great if you could share toml config for the same here for the now. Thank you!

Hareramrai avatar Jun 27 '24 14:06 Hareramrai

[servers.ws]
addr = "127.0.0.1:6188"
locations = ["ws"]

[locations.ws]
upstream = "ws"

[upstreams.ws]
addrs = ["124.222.224.186:8800"]

I tested it on http://www.websocket-test.com/

image

vicanso avatar Jun 27 '24 14:06 vicanso

@vicanso, thanks for sharing the configuration!

Do you have any documentation for using https://hub.docker.com/r/vicanso/pingap with a docker-compose setup?

Hareramrai avatar Jun 28 '24 11:06 Hareramrai

Sorry, I don't.

vicanso avatar Jun 28 '24 11:06 vicanso

@vicanso, do the docker images support web UI?

Hareramrai avatar Jun 28 '24 12:06 Hareramrai

Yes. cGluZ2FwOjEyMzEyMw== is base64("pingap:123123").

docker run -it -d --restart=always \
  -v $PWD/pingap:/opt/pingap \
  -p 3018:3018 \
  vicanso/pingap -c /opt/pingap [email protected]:3018

vicanso avatar Jun 28 '24 13:06 vicanso