Add support for HTTPupgrade custom headers
This commit is contained in:
1 parent
bd38578978
commit
9a619f9e7c
4 files changed
+55
-30
No files matched your search
@@ -183,6 +183,7 @@ func (c *WebSocketConfig) Build() (proto.Message, error) {
|
||||
type HttpUpgradeConfig struct {
|
||||
Path string `json:"path"`
|
||||
Host string `json:"host"`
|
||||
Headers map[string]string `json:"headers"`
|
||||
AcceptProxyProtocol bool `json:"acceptProxyProtocol"`
|
||||
}
|
||||
|
||||
@@ -202,6 +203,7 @@ func (c *HttpUpgradeConfig) Build() (proto.Message, error) {
|
||||
config := &httpupgrade.Config{
|
||||
Path: path,
|
||||
Host: c.Host,
|
||||
Header: c.Headers,
|
||||
AcceptProxyProtocol: c.AcceptProxyProtocol,
|
||||
Ed: ed,
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user