orbiter/api/router.go
Gianluca Arbezzano 747f564a7a First commit
2017-02-21 00:07:57 +00:00

14 lines
315 B
Go

package api
import (
"github.com/gianarb/orbiter/core"
"github.com/gorilla/mux"
)
func GetRouter(core core.Core) *mux.Router {
r := mux.NewRouter()
r.HandleFunc("/handle/{autoscaler_name}/{service_name}", Handle(core.Autoscalers)).Methods("POST")
r.HandleFunc("/health", Health()).Methods("GET")
return r
}