Skip to content

Commit c0bcf41

Browse files
committed
fix serve
1 parent d75361d commit c0bcf41

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

components/supervisor/pkg/ports/ports.go

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,11 @@ func (pm *Manager) updateState(ctx context.Context, exposed []ExposedPort, serve
272272
continue
273273
}
274274

275+
config, _, exists := pm.configs.Get(port.Port)
276+
if exists && config.OnOpen == "ignore-completely" {
277+
continue
278+
}
279+
275280
current, exists := servedMap[port.Port]
276281
if !exists || (!port.BoundToLocalhost && current.BoundToLocalhost) {
277282
servedMap[port.Port] = port
@@ -789,9 +794,7 @@ func (pm *Manager) getStatus() []*api.PortsStatus {
789794
res := make([]*api.PortsStatus, 0, len(pm.state))
790795
for port := range pm.state {
791796
status := pm.getPortStatus(port)
792-
if status.OnOpen != api.PortsStatus_ignore_completely {
793-
res = append(res, status)
794-
}
797+
res = append(res, status)
795798
}
796799
sort.SliceStable(res, func(i, j int) bool {
797800
// Max number of port 65536

0 commit comments

Comments
 (0)