Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Daemon ¶
type Daemon struct {
// contains filtered or unexported fields
}
Daemon is the fully-wired daemon. One instance per process.
func New ¶
New constructs and fully wires a Daemon. Returns an error if any subsystem fails to initialise — no partial startup.
func (*Daemon) Reload ¶
Reload re-reads the config file and applies live-reloadable settings. Settings that require a restart are logged as warnings and skipped.
func (*Daemon) Run ¶
Run starts the proxy and blocks until the context is cancelled or the proxy errors out. SIGHUP triggers a live config reload without stopping the proxy.
func (*Daemon) SetUpstreamTransport ¶
func (d *Daemon) SetUpstreamTransport(rt http.RoundTripper)
SetUpstreamTransport replaces the transport used to forward requests to the upstream origin. Intended for testing only — inject a transport that dials a local httptest.Server so tests don't need real DNS or internet access.