mirror of
https://github.com/openziti/zrok.git
synced 2024-12-11 17:30:48 +01:00
22 lines
356 B
Go
22 lines
356 B
Go
package healthUi
|
|
|
|
import (
|
|
"github.com/sirupsen/logrus"
|
|
"net/http"
|
|
)
|
|
|
|
func WriteHealthOk(w http.ResponseWriter) {
|
|
if data, err := FS.ReadFile("index.html"); err == nil {
|
|
w.WriteHeader(http.StatusOK)
|
|
n, err := w.Write(data)
|
|
if n != len(data) {
|
|
logrus.Errorf("short write")
|
|
return
|
|
}
|
|
if err != nil {
|
|
logrus.Error(err)
|
|
return
|
|
}
|
|
}
|
|
}
|