Documentation ¶
Index ¶
Constants ¶
View Source
const ( // BehaviorStatusFound : プロキシの宛先が見つかった BehaviorStatusFound = "found" // BehaviorStatusNotFound : プロキシの宛先が見つからなった BehaviorStatusNotFound = "notfound" )
View Source
const ( // ProxyHeaderBehavior : プロキシの結果を格納するヘッダの名前 ProxyHeaderBehavior = "X-Proxy-Behavior" // ProxyHeaderControl : プロキシのコントローラを呼び出すためのヘッダの名前 ProxyHeaderControl = "X-Proxy-Control" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Behavior ¶
type Behavior struct { PathPrefix string `json:"pathPrefix" yaml:"pathPrefix"` OriginKey string `json:"originKey" yaml:"originKey"` }
Behavior : パスごとのプロキシ先設定
type Handler ¶
type Handler struct { Origins []*Origin `json:"origins" yaml:"origins"` Behaviors []Behavior `json:"behaviors" yaml:"behaviors"` Addr string `json:"-" yaml:"addr"` API API `json:"-" yaml:"api"` StartPath string `json:"-" yaml:"startPath"` HideControl bool `json:"-" yaml:"hideControl"` // contains filtered or unexported fields }
Handler : リバースプロキシ
func (*Handler) ListenAndServe ¶
ListenAndServe : サーバーを起動する
Click to show internal directories.
Click to hide internal directories.