package main

import (
	"context"
	"log"
	"net/http"
)

func main() {
	ctx := context.Background()
	InitDatabase(ctx)

	http.HandleFunc("/ws", ServeWsConnection)
	http.HandleFunc("/new/client", RegisterHandler)
	http.HandleFunc("/new/token", LoginHandler)

	log.Println("listening on :8080")
	log.Fatal(http.ListenAndServe(":8080", nil))
}
