diff --git a/backend/app/service/ssh.go b/backend/app/service/ssh.go index f0f0cdc67700..15d353f14805 100644 --- a/backend/app/service/ssh.go +++ b/backend/app/service/ssh.go @@ -177,7 +177,11 @@ func (u *SSHService) Update(req dto.SSHUpdate) error { }, } if err := NewIFirewallService().UpdatePortRule(ruleItem); err != nil { - global.LOG.Errorf("reset firewall rules %s -> %s failed, err: %v", req.OldValue, req.OldValue, err) + global.LOG.Errorf("reset firewall rules %s -> %s failed, err: %v", req.OldValue, req.NewValue, err) + } + + if err = NewIHostService().Update(1, map[string]interface{}{"port": req.NewValue}); err != nil { + global.LOG.Errorf("reset host port %s -> %s failed, err: %v", req.OldValue, req.NewValue, err) } }