Exemplo n.º 1
0
func (reg *registryApi) Routes(context string, router *server.Router) {
	routes := server.RouteMap{
		"GET": {
			"/status":                     reg.handleStatus,
			"/search":                     reg.handleSearch,
			"/images/{front}/tags":        reg.handleTags,
			"/images/{front}/{tail}/tags": reg.handleTags,
		},
		"POST": {
			"/analyze": reg.handleAnalysis,
		},
	}

	router.AddCorsRoutes(context, routes)
}