AppManager: Fix port reservation during update
Change-Id: I5262f13b1dcd9f0ac192c9e80f43e40409ae4182
diff --git a/core/installer/app_manager.go b/core/installer/app_manager.go
index c98be4b..a4140c0 100644
--- a/core/installer/app_manager.go
+++ b/core/installer/app_manager.go
@@ -222,7 +222,6 @@
}
func openPorts(ports []PortForward, reservations map[string]reservePortResp, allocators map[string]string, ns string) error {
- fmt.Printf("-- %+v\n-- %+v\n--%+v\n", ports, reservations, allocators)
for _, p := range ports {
var target string
if p.Cluster == "" {
@@ -665,7 +664,6 @@
portFields = append(portFields, np)
}
}
- fmt.Printf("%+v %+v %+v\n", oldPorts, newPorts, portFields)
fakeReservations := map[string]reservePortResp{}
for i, f := range portFields {
fakeReservations[f] = reservePortResp{Port: i}
@@ -750,7 +748,7 @@
break
}
}
- if !found {
+ if found {
toOpen = append(toOpen, op)
}
}