在 Hudson 或 Jenkins 中,如何恢复已删除的构建?
我不小心删除了一些我宁愿保留的工作的构建。我从备份中恢复了磁盘上的构建,但当我位于该作业的状态页面上时,它们仍然没有显示。
我尝试过触发另一个工作构建并重新启动 Hudson。
我怎样才能完全恢复这些构建? Hudson 是否有用于存储此类信息的数据库?
I accidentally deleted some builds for a job that I would have rather kept. I restored the builds on disk from backup, but they still do not show up when I am on the status page for that job.
I have tried both triggering another build for the job and re-starting Hudson.
How can I fully-restore these builds? Is there a DB that Hudson uses to store this type of information?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
取决于你恢复了什么。听起来您恢复了工作区文件夹,但该文件夹与历史信息无关。我会首先关闭 Hudson,然后恢复构建文件夹和模块文件夹。然后你就可以重新启动Hudson了。欲了解更多信息,请询问 Hudson 项目。
Depends what you restored. It sounds like you restored the workspace folder, but this folder is irrelevant for historical information. I would first shut down Hudson and than restore the build folder and the modules folder. Than you can restart Hudson. For more information ask the Hudson project.
除了 Williams (https://stackoverflow.com/a/3399103/142207) 答案之外,您还需要重新- 将其添加到所有自定义视图中。
In addition to Williams (https://stackoverflow.com/a/3399103/142207) answer you'll need to re-add it to all the custom views.
在您的 %HUDSON_HOME% 目录中有一个名为“jobs”的子目录。 “jobs”下是每个项目的子目录。每个目录中都有每个构建的子目录。
您需要确保 jobs\<projectname>存在,然后将缺少的构建目录复制到里面。
单击“管理 Hudson/从磁盘重新加载配置”以使 Hudson 识别新添加的构建。如果您使用 Servlet 容器(例如 Tomcat),则无需重新启动它。
Inside your %HUDSON_HOME% directory is a subdirectory called "jobs". Under "jobs" are subdirectories for every project. Inside each one are subdirectories for each build.
You need to make sure that jobs\<projectname> exists, and then copy the missing build directories inside.
Click "Manage Hudson/Reload Configuration From Disk" to make Hudson recognize the newly added builds. Not necessary to restart your servlet container (e.g. Tomcat) if you use one.