1
0
mirror of https://github.com/1Panel-dev/1Panel.git synced 2025-01-19 08:19:15 +08:00

fix: 解决容器切换端口选项时,仍然进行端口校验的问题 (#2277)

This commit is contained in:
ssongliu 2023-09-13 17:12:14 +08:00 committed by GitHub
parent a241fb32d2
commit cab0c7938d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View File

@ -180,7 +180,7 @@ func handleAppRecover(install *model.AppInstall, recoverFile string, isRollback
if err != nil {
return err
}
if resource.Key == "mysql" || resource.Key == "maraidb" {
if resource.Key == "mysql" || resource.Key == "mariadb" {
mysqlInfo, err := appInstallRepo.LoadBaseInfo(resource.Key, resourceApp.Name)
if err != nil {
return err

View File

@ -417,8 +417,12 @@ const onSubmit = async (formEl: FormInstance | undefined) => {
if (dialogData.value.rowData!.entrypointStr) {
dialogData.value.rowData!.entrypoint = dialogData.value.rowData!.entrypointStr.split(' ');
}
if (!checkPortValid()) {
return;
if (dialogData.value.rowData!.publishAllPorts) {
dialogData.value.rowData!.exposedPorts = [];
} else {
if (!checkPortValid()) {
return;
}
}
dialogData.value.rowData!.memory = Number(dialogData.value.rowData!.memory);
dialogData.value.rowData!.nanoCPUs = Number(dialogData.value.rowData!.nanoCPUs);