Documentation
¶
Index ¶
- func CheckAuth(r *http.Request, w http.ResponseWriter) bool
- func Commands() *mux.Router
- func DelRedisKey(key string) int64
- func ErrorMessage(number int, function string, msg string) []byte
- func GetAllRedisKeys(pattern string) *goredis.ScanIterator
- func GetRedisKey(key string) string
- func GetTaskFromEvent(update *mesosproto.Event_Update) mesosutil.Command
- func SaveConfig()
- func SetConfig(cfg *cfg.Config, frm *mesosutil.FrameworkConfig)
- func V0ComposeKillService(w http.ResponseWriter, r *http.Request)
- func V0ComposeKillTask(w http.ResponseWriter, r *http.Request)
- func V0ComposePush(w http.ResponseWriter, r *http.Request)
- func V0ComposeRestartService(w http.ResponseWriter, r *http.Request)
- func V0ComposeUpdate(w http.ResponseWriter, r *http.Request)
- func V0ShowAllTasks(w http.ResponseWriter, r *http.Request)
- func Versions(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckAuth ¶
func CheckAuth(r *http.Request, w http.ResponseWriter) bool
CheckAuth will check if the token is valid
func ErrorMessage ¶
ErrorMessage will create a message json
func GetAllRedisKeys ¶
func GetAllRedisKeys(pattern string) *goredis.ScanIterator
GetAllRedisKeys get out all redis keys to a patter
func GetTaskFromEvent ¶
func GetTaskFromEvent(update *mesosproto.Event_Update) mesosutil.Command
GetTaskFromEvent get out the key by a mesos event
func SetConfig ¶
func SetConfig(cfg *cfg.Config, frm *mesosutil.FrameworkConfig)
SetConfig set the global config
func V0ComposeKillService ¶
func V0ComposeKillService(w http.ResponseWriter, r *http.Request)
V0ComposeKillService will kill a task from a service from a specific project example: curl -X DELETE http://user:password@127.0.0.1:10000/api/compose/v0/{projectname}/{servicename}/{taskid}
func V0ComposeKillTask ¶
func V0ComposeKillTask(w http.ResponseWriter, r *http.Request)
V0ComposeKillTask will kill a task from a service from a specific project example: curl -X DELETE http://user:password@127.0.0.1:10000/api/compose/v0/{projectname}/{servicename}/{taskid}
func V0ComposePush ¶
func V0ComposePush(w http.ResponseWriter, r *http.Request)
V0ComposePush will read and interpret the docker-compose.yml example: curl -X GET http://user:password@127.0.0.1:10000/api/compose/v0 --data-binary @docker-compose.yml
func V0ComposeRestartService ¶
func V0ComposeRestartService(w http.ResponseWriter, r *http.Request)
V0ComposeRestartService will restart a service from a specific project example: curl -X PUT http://user:password@127.0.0.1:10000/api/compose/v0/{projectname}/{servicename}/restart
func V0ComposeUpdate ¶
func V0ComposeUpdate(w http.ResponseWriter, r *http.Request)
V0ComposeUpdate will update the docker-compose.yml example: curl -X GET http://user:password@127.0.0.1:10000/api/compose/v0 --data-binary @docker-compose.yml
func V0ShowAllTasks ¶
func V0ShowAllTasks(w http.ResponseWriter, r *http.Request)
V0ShowAllTasks will print out all tasks example: curl -X GET http://user:password@127.0.0.1:10000/api/compose/v0/tasks
Types ¶
This section is empty.