mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-02-08 01:20:07 +08:00
fix: 解决创建网站报端口被占用的问题 (#2699)
Refs https://github.com/1Panel-dev/1Panel/issues/2695
This commit is contained in:
parent
048df6f390
commit
6c957d157b
@ -227,8 +227,8 @@ func (w WebsiteService) CreateWebsite(create request.WebsiteCreate) (err error)
|
|||||||
errMap["name"] = runtime.Name
|
errMap["name"] = runtime.Name
|
||||||
return buserr.WithMap("ErrPortExist", errMap, nil)
|
return buserr.WithMap("ErrPortExist", errMap, nil)
|
||||||
}
|
}
|
||||||
if common.ScanPort(create.Port) {
|
if common.ScanPort(port) {
|
||||||
return buserr.WithDetail(constant.ErrPortInUsed, create.Port, nil)
|
return buserr.WithDetail(constant.ErrPortInUsed, port, nil)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user