We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b0537e8 commit 280c768Copy full SHA for 280c768
info.go
@@ -0,0 +1,14 @@
1
+package main
2
+
3
+import (
4
+ "github.com/gin-gonic/gin"
5
+)
6
7
+func infoHandler(c *gin.Context) {
8
+ c.JSON(200, gin.H{
9
+ "http": "http://localhost" + port,
10
+ "https": "https://localhost" + port,
11
+ "ws": "ws://localhost" + port,
12
+ "wss": "wss://localhost" + portSSL,
13
+ })
14
+}
main.go
@@ -209,6 +209,7 @@ func main() {
209
r.POST("/socket.io/", socketHandler)
210
r.Handle("WS", "/socket.io/", socketHandler)
211
r.Handle("WSS", "/socket.io/", socketHandler)
212
+ r.GET("/info", infoHandler)
213
go func() {
214
start := 49152
215
end := 65535
0 commit comments