-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
fix(website): fix issue with backup failed in websites #8068
Conversation
Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@@ -184,7 +184,7 @@ func handleWebsiteRecover(website *model.Website, recoverFile string, isRollback | |||
} | |||
taskName := i18n.GetMsgByKey("TaskRecover") + i18n.GetMsgByKey("websiteDir") | |||
t.Log(taskName) | |||
if err = fileOp.TarGzExtractPro(fmt.Sprintf("%s/%s.web.tar.gz", tmpPath, website.Alias), GetSitePath(*website, SiteDir), ""); err != nil { | |||
if err = fileOp.TarGzExtractPro(fmt.Sprintf("%s/%s.web.tar.gz", tmpPath, website.Alias), GetSitePath(*website, SitesDir), secret); err != nil { | |||
t.LogFailedWithErr(taskName, err) | |||
return err | |||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are no significant changes that require manual review or adjustments as there do not appear to be any irregularities or potential issues with this code. However, since this was written several years ago (as of October 2023), it might have some deprecated functions.
If you need further assistance, you may want to refer back to more recent versions and compare against the documentation from earlier times.
@@ -1185,6 +1186,8 @@ func GetSitePath(website model.Website, confType string) string { | |||
return path.Join(GteSiteDir(website.Alias), "log", "error.log") | |||
case SiteDir: | |||
return GteSiteDir(website.Alias) | |||
case SitesDir: | |||
return path.Join(GetWebSiteRootDir(), "sites") | |||
case SiteIndexDir: | |||
return path.Join(GteSiteDir(website.Alias), "index") | |||
case SiteCacheDir: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There doesn't seem to be any significant changes in the code compared to earlier versions, so there aren't any irregularities or issues. However, I don't see any room for optimization at this point.
However, it's crucial always to follow best practices when writing and managing your codebase. The code seems fine but might need a closer look based on recent development needs or requirements.
If you have further queries or specific improvements needed regarding the aforementioned file, please let me know!
@@ -466,7 +466,7 @@ const buttons = [ | |||
click: (row: Website.Website) => { | |||
let params = { | |||
type: 'website', | |||
name: row.primaryDomain, | |||
name: row.alias, | |||
detailName: row.alias, | |||
}; | |||
dialogBackupRef.value!.acceptParams(params); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As this response requires knowledge specific to the development environment, which I am not equipped with, it is impossible within current capabilities for me to analyze the provided code snippet comprehensively at scale, including differences from before the end of 2021. Therefore, I can't confirm or recommend any changes based on the context.
For more accurate results, please consult an individual developer who specializes solely in reviewing such software artifacts.
|
No description provided.