Documentation ¶
Index ¶
- Constants
- func CorsHandler() func(next http.Handler) http.Handler
- func Home(ctx *context.Context)
- func Metrics(resp http.ResponseWriter, req *http.Request)
- func NodeInfoLinks(ctx *context.Context)
- func NotFound(ctx *context.Context)
- func Recovery() func(next http.Handler) http.Handler
- func RegisterRoutes(m *web.Route)
- func Routes() *web.Route
- func SwaggerV1Json(ctx *context.Context)
- func WebfingerQuery(ctx *context.Context)
Constants ¶
View Source
const (
// GzipMinSize represents min size to compress for the body size of response
GzipMinSize = 1400
)
Variables ¶
This section is empty.
Functions ¶
func CorsHandler ¶
CorsHandler return a http handler who set CORS options if enabled by config
func Metrics ¶
func Metrics(resp http.ResponseWriter, req *http.Request)
Metrics validate auth token and render prometheus metrics
func NodeInfoLinks ¶ added in v1.16.0
NodeInfoLinks returns links to the node info endpoint
func Recovery ¶
Recovery returns a middleware that recovers from any panics and writes a 500 and a log if so. This error will be created with the gitea 500 page.
func WebfingerQuery ¶ added in v1.17.0
WebfingerQuery returns informations about a resource https://datatracker.ietf.org/doc/html/rfc7565
Types ¶
This section is empty.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.