Documentation ¶
Overview ¶
Package proxy is a generated GoMock package.
Index ¶
Constants ¶
const ( // ProxyPortStart is the first port that will be allocated by the proxy component. // Others will be incremented by 1 each time ProxyPortStart = "9400" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type MockProxy ¶ added in v1.0.14
type MockProxy struct {
// contains filtered or unexported fields
}
MockProxy is a mock of Proxy interface.
func NewMockProxy ¶ added in v1.0.14
func NewMockProxy(ctrl *gomock.Controller) *MockProxy
NewMockProxy creates a new mock instance.
func (*MockProxy) AddProxyForward ¶ added in v1.0.14
func (m *MockProxy) AddProxyForward(name string, proxyForward *ProxyForward)
AddProxyForward mocks base method.
func (*MockProxy) EXPECT ¶ added in v1.0.14
func (m *MockProxy) EXPECT() *MockProxyMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockProxyMockRecorder ¶ added in v1.0.14
type MockProxyMockRecorder struct {
// contains filtered or unexported fields
}
MockProxyMockRecorder is the mock recorder for MockProxy.
func (*MockProxyMockRecorder) AddProxyForward ¶ added in v1.0.14
func (mr *MockProxyMockRecorder) AddProxyForward(name, proxyForward interface{}) *gomock.Call
AddProxyForward indicates an expected call of AddProxyForward.
func (*MockProxyMockRecorder) Listen ¶ added in v1.0.14
func (mr *MockProxyMockRecorder) Listen() *gomock.Call
Listen indicates an expected call of Listen.
func (*MockProxyMockRecorder) Stop ¶ added in v1.0.14
func (mr *MockProxyMockRecorder) Stop() *gomock.Call
Stop indicates an expected call of Stop.
type Proxy ¶
type Proxy interface { Listen() error Stop() error AddProxyForward(name string, proxyForward *ProxyForward) }
type ProxyForward ¶
type ProxyForward struct { Name string Hostname string ProxyHostname string LocalPort string ForwardPort string LocalIP string ProxyPort string }
func NewProxyForward ¶
func NewProxyForward(name, hostname, proxyHostname, localPort, forwardPort string) *ProxyForward
NewProxyForward returns a new proxy port-forward instance
func (*ProxyForward) GetHostname ¶ added in v0.0.4
func (p *ProxyForward) GetHostname() string
GetHostname returns the hostname (if defined) of this proxy forward, elsewhere uses the service name
func (*ProxyForward) GetProxifiedPorts ¶
func (p *ProxyForward) GetProxifiedPorts() string
GetProxifiedPorts returns the couple of proxified ports (proxy attributed port:forward port)
func (*ProxyForward) GetProxyHostname ¶ added in v0.0.9
func (p *ProxyForward) GetProxyHostname() string
GetProxyHostname returns the proxy sender hostname depending on forward type In case of a forward type 'proxy', it will return the specified proxy hostname, elsewhere it will return 127.0.0.1 because other forwards forward traffic locally
func (*ProxyForward) SetLocalIP ¶ added in v0.0.4
func (p *ProxyForward) SetLocalIP(ip string)
SetLocalIP sets local attributed IP to this forward
func (*ProxyForward) SetProxyPort ¶
func (p *ProxyForward) SetProxyPort(port string)
SetProxyPort sets proxy attributed port to this forward