Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: release products use retag image registry #32

Merged
merged 1 commit into from
Nov 22, 2023

Conversation

CeerDecy
Copy link
Member

Description

release products use retag image registry

@@ -338,4 +338,6 @@ release action 运行成功后会在当前目录生成 `dicehub-release` 文件
registryUsername: ${{ secrets.REGISTRY_USERNAME }}
# 远端镜像仓库的密码
registryPassword: ${{ secrets.REGISTRY_PASSWORD }}
# 制品 不使用retag中镜像地址
notRetag: true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

notRetag points to ambiguity, what is needed is the replacement of the image in the dice release, rather than determining whether to execute a retag. @CeerDecy

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have change to releaseImgNotRetag

RetagImage string `json:"retagImage"`
RegistryUsername string `json:"registryUsername"`
RegistryPassword string `json:"registryPassword"`
ReleaseImgNotRetag bool `json:"releaseImgNotRetag"` // 是否使用RetagImage对应的镜像仓库,默认false为使用RetagReg的镜像仓库,true为同时上传两个镜像仓库【默认镜像】和【Retag镜像】,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

useRetagImage

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change ReleaseImgNotRetag tag name to useRetagImage

Copy link
Member

@iutx iutx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if cfg.Services != nil {
insertCommands(&dCopy, cfg)
// 默认将制品中使用的镜像修改成retag中的镜像
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do not impact the existing functionality; the logic for useRetagImage should not take effect if the user has not provided RetagImage.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added RetagImage == "" judgment logic in the useRetagImage function

@iutx
Copy link
Member

iutx commented Nov 20, 2023

/lgtm @sfwn

@sfwn
Copy link
Member

sfwn commented Nov 22, 2023

/approve

@erda-bot erda-bot added the approved Approve merging these changes label Nov 22, 2023
erda-bot
erda-bot previously approved these changes Nov 22, 2023
@CeerDecy CeerDecy force-pushed the feature/registry-by-retag branch from 6111198 to 8398288 Compare November 22, 2023 05:43
@sfwn
Copy link
Member

sfwn commented Nov 22, 2023

/approve

@erda-bot erda-bot merged commit 67bd3b6 into erda-project:master Nov 22, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Approve merging these changes
Development

Successfully merging this pull request may close these issues.

5 participants