Added a rudimentary client.

This commit is contained in:
2025-02-03 21:17:49 +01:00
parent fd41e0c03e
commit e7e8953ec3
5 changed files with 80 additions and 8 deletions

View File

@ -9,16 +9,14 @@ import (
"github.com/gorilla/websocket"
)
func (server *Server) Start() error {
func (server *Server) Start() {
// Start the server
http.HandleFunc("/ws", func(w http.ResponseWriter, r *http.Request) {
handleConnections(w, r)
})
log.Fatal(http.ListenAndServe(server.ListenAddress+":"+strconv.Itoa(server.ListenPort), nil))
time.Sleep(600 * time.Second)
return nil
// return nil
}
var upgrader = websocket.Upgrader{