TUN-3725: Warp-routing is independent of ingress

- Changed warp-routing configuration to its own yaml.
    - Ingress Rules host matching is indepedent of warp-routing.
This commit is contained in:
Sudarsan Reddy
2021-01-17 20:22:53 +00:00
committed by Nuno Diegues
parent 368066a966
commit b4700a52e3
11 changed files with 130 additions and 53 deletions

View File

@@ -78,20 +78,22 @@ func (o *httpService) String() string {
// bridgeService is like a jump host, the destination is specified by the client
type bridgeService struct {
client *tcpClient
client *tcpClient
serviceName string
}
// if streamHandler is nil, a default one is set.
func newBridgeService(streamHandler streamHandlerFunc) *bridgeService {
func newBridgeService(streamHandler streamHandlerFunc, serviceName string) *bridgeService {
return &bridgeService{
client: &tcpClient{
streamHandler: streamHandler,
},
serviceName: serviceName,
}
}
func (o *bridgeService) String() string {
return "bridge service"
return ServiceBridge + ":" + o.serviceName
}
func (o *bridgeService) start(wg *sync.WaitGroup, log *zerolog.Logger, shutdownC <-chan struct{}, errC chan error, cfg OriginRequestConfig) error {