Add Worker Version Check
This commit is contained in:
parent
a0f3d5e439
commit
595efd0c66
3 changed files with 8 additions and 0 deletions
|
@ -32,6 +32,10 @@ func handleWorkerWebsocket(w http.ResponseWriter, r *http.Request) {
|
|||
w.WriteHeader(http.StatusUnauthorized)
|
||||
return
|
||||
}
|
||||
if r.Header.Get(constants.WORKER_VERSION_HEADER) != constants.WORKER_VERSION {
|
||||
w.WriteHeader(http.StatusNotImplemented)
|
||||
return
|
||||
}
|
||||
c, err := websocket.Accept(w, r, &websocket.AcceptOptions{
|
||||
InsecureSkipVerify: true,
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue