Documentation
¶
Index ¶
- type CellReverseProxy
- func (CellReverseProxy) CaddyModule() caddy.ModuleInfo
- func (cp *CellReverseProxy) Provision(ctx caddy.Context) error
- func (cp CellReverseProxy) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyhttp.Handler) error
- func (cp *CellReverseProxy) UnmarshalCaddyfile(d *caddyfile.Dispenser) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CellReverseProxy ¶
type CellReverseProxy struct {
// DockerHost specifies the Docker socket to connect to (e.g. unix:///var/run/docker.sock).
DockerHost string `json:"docker_host,omitempty"`
// WaitTimeout is how long to wait for a container to become healthy.
WaitTimeout time.Duration `json:"wait_timeout,omitempty"`
// contains filtered or unexported fields
}
CellReverseProxy is a Caddy module that routes requests by subdomain to Docker containers.
func (CellReverseProxy) CaddyModule ¶
func (CellReverseProxy) CaddyModule() caddy.ModuleInfo
CaddyModule returns the module information.
func (*CellReverseProxy) Provision ¶
func (cp *CellReverseProxy) Provision(ctx caddy.Context) error
Provision sets up the Docker client and starts the refresh loop.
func (CellReverseProxy) ServeHTTP ¶
func (cp CellReverseProxy) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyhttp.Handler) error
ServeHTTP routes incoming HTTP requests to the appropriate Docker container.
func (*CellReverseProxy) UnmarshalCaddyfile ¶
func (cp *CellReverseProxy) UnmarshalCaddyfile(d *caddyfile.Dispenser) error
UnmarshalCaddyfile parses Caddyfile tokens.
Click to show internal directories.
Click to hide internal directories.