package
0.0.0-20250306163500-5f3bb2705e1f
Repository: https://github.com/versoriumx/teleport.git
Documentation: pkg.go.dev

# Functions

New returns a new reverse proxy that forwards to the given url.
NewHeaderRewriter creates a new HeaderRewriter.
WithErrorHandler sets the error handler for the forwarder.
WithFlushInterval sets the flush interval for the forwarder.
WithLogger sets the logger for the forwarder.
WithLogWriter sets the writer for the stdlib logger to use a different io.Writer than the default one created when using WithLogger.
WithPassHostHeader sets whether the Host header should be passed to the forwarded request.
WithResponseModifier sets the response modifier for the forwarder.
WithRewriter sets the header rewriter for the forwarder.
WithRoundTripper sets the round tripper for the forwarder.

# Constants

ContentLength is the Content-Length header.
X-* Header names.
X-* Header names.
X-* Header names.
X-* Header names.
X-* Header names.
X-* Header names.

# Variables

DefaultHandler is the default error handler.
XHeaders X-* headers.

# Structs

Forwarder is a reverse proxy that forwards http requests to another server.
HeaderRewriter re-sets the X-Forwarded-* headers and sets X-Real-IP header.

# Interfaces

ErrorHandler is an interface for handling errors.
Rewriter is an interface for rewriting http requests.

# Type aliases

ErrorHandlerFunc is an adapter to allow the use of ordinary functions as error handlers.
Option is a functional option for the forwarder.