-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(ai): 修复AI(beta)系统中无法删除创建失败的镜像的问题 (#1118)
### 问题原因: Harbor中找不到对应镜像时会直接抛出错误,终止删除数据 导致就算是创建失败的镜像,因为在Harbor中没有找到对应镜像而无法删除本地数据 关联bug [创建失败的镜像无法删除](PKUHPC/scow-ai-internal-dev#20) ### 解决方案: 由于在前面的代码中已经处理了调用Harbor删除API无法正常返回的情况 在这之后Harbor中找不到对应镜像时应该无论镜像是什么状态直接删除本地数据,以保证数据的一致性 同时此PR还修复了删除镜像api调用时协议引入的错误,不应该引入scow访问协议,在HarborConfig中增加了Harbor访问协议的配置,默认值为`http` 当前ai-beta只有支持`http`协议访问的测试环境,后续完成https服务的测试后再继续补充该配置项在文档中的说明 ### 修改后: 删除创建失败的镜像 ![image](https://github.com/PKUHPC/SCOW/assets/43978285/ce158cfa-8742-4138-a325-cd6cc204a58f) 执行删除操作,删除成功 ![image](https://github.com/PKUHPC/SCOW/assets/43978285/6917cf7d-8745-4ef5-bf11-fa7eb17685c9) 后台打印了执行删除时的日志 ![image](https://github.com/PKUHPC/SCOW/assets/43978285/85e71f18-fe4c-4e78-8296-664eced30ba7) --------- Co-authored-by: ZihanChen821 <[email protected]>
- Loading branch information
1 parent
2f7590a
commit 3242957
Showing
4 changed files
with
20 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@scow/ai": patch | ||
--- | ||
|
||
修复创建失败的镜像无法删除的问题 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@scow/config": patch | ||
--- | ||
|
||
在 aiConfig 下的 harborConfig 配置中增加 protocol 配置,默认值为 "http" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters