An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 8.2% on proxy.golang.org

proxy.golang.org : github.com/mu-box/microbox-router

Package router is a client for creating/maintaining http(s) proxies. Certificates are stored as a KeyPair which contains the key and certificate. A tls.Certificate is created and stored separately and used for serving https clients. If a certificate is added, a tls listener will be created, and the X-Forwarded-Proto header will be set to "https" before the request gets proxied to the target. The certificate's Common Name must be set in order for the router to serve it to a matching incoming request. Start secure routing as follows: Set certificates as follows: Get certificates (key/cert pairs) as follows: Routes have 2 implicit parts: matching criteria and action definitions. The matching portion includes subdomain, domain, and path. The matching algorighm is recursive, so a request to "admin.test.com" would still match the registered route `Route{Domain:"test.com"}`. Precedence is given to routes that match the request's subdomain (if any). Routes with the longest matching path are also prioritized (e.g. a request to "test.com/admin" would match "/admin" in `[]Route{Route{Path:"/"},Route{Path:"/admin"}}` because "/admin" is longer than "/"). The action portion includes targets, fwdpath, and page. If page is specified, it gets served to the client when the request matches that route. Targets is a list of backend servers to proxy to. A target can include a path which, by default, will be prepended to the request's path prior to proxying. If fwdpath is set, it will be appended to any target path and used as the path forwarded to the target. Start routing as follows: Set routes as follows: Get registered routes as follows: Requests will always match the route with the longest path defined. A path can include a "*" at the end to match similar requests. A subdomain match takes precedence over a domain/path match. If a Route's matcher has a subdomain only, then all requests with that particular subdomain will have the Route's defined action applied. In order to view logs embedded within microbox-router, you must: and set the level of logging desired (see lumber docs for more info)

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/mu-box/microbox-router
License: MIT
Latest release: almost 2 years ago
First release: about 7 years ago
Namespace: github.com/mu-box
Stars: 0 on GitHub
Forks: 0 on GitHub
See more repository details: repos.ecosyste.ms
Funding links: https://github.com/sponsors/mu-box
Last synced: 4 days ago

    Loading...
    Readme
    Loading...