mirror of
https://github.com/containers/podman.git
synced 2025-06-20 17:13:43 +08:00
Merge pull request #2658 from mheon/sctp
Add support for SCTP port forwarding
This commit is contained in:
@ -183,6 +183,7 @@ func waitPidsStop(pids []int, timeout time.Duration) error {
|
||||
|
||||
func bindPorts(ports []ocicni.PortMapping) ([]*os.File, error) {
|
||||
var files []*os.File
|
||||
notifySCTP := false
|
||||
for _, i := range ports {
|
||||
switch i.Protocol {
|
||||
case "udp":
|
||||
@ -218,6 +219,12 @@ func bindPorts(ports []ocicni.PortMapping) ([]*os.File, error) {
|
||||
}
|
||||
files = append(files, f)
|
||||
break
|
||||
case "sctp":
|
||||
if !notifySCTP {
|
||||
notifySCTP = true
|
||||
logrus.Warnf("port reservation for SCTP is not supported")
|
||||
}
|
||||
break
|
||||
default:
|
||||
return nil, fmt.Errorf("unknown protocol %s", i.Protocol)
|
||||
|
||||
|
Reference in New Issue
Block a user