简体   繁体   English

Html publisher - 无法将 html 报告复制到工作区中的其他路径

[英]Html plublisher - Could not copy html report to other path within workspace

Trying to copy the HTML publisher report to another path in same workspace.尝试将 HTML 发布者报告复制到同一工作区中的另一个路径。

Added below script in jenkinsfile在 jenkinsfile 中添加了以下脚本

  publishHTML([allowMissing: false, alwaysLinkToLastBuild: false,includes: '**/*.png', keepAll: true, reportDir: target/cucumber-html-reports', reportFiles: report.html', reportName: 'HTMLReport', reportTitles: ''])

Jenkins Console log詹金斯控制台日志

    [htmlpublisher] Archiving HTML reports...

    [htmlpublisher] Archiving at BUILD level /apps/cloudbees-je/cloudbees-data/workspace/TEST/all_test/target/cucumber-html-reports to    /apps/jenkins/cloudbees-data/jobs/TEST/jobs/all_test/builds/42/htmlreports/HTMLReport

I am trying to copy the HTML publisher output “/apps/jenkins/cloudbees-data/jobs/TEST/jobs/all_test/builds/42/htmlreports/HTMLReport" To ${env.WORKSPACE}/report by running below script in jenkinsfile我正在尝试通过在 jenkinsfile 中运行以下脚本将 HTML 发布者输出“/apps/jenkins/cloudbees-data/jobs/TEST/jobs/all_test/builds/42/htmlreports/HTMLReport”复制到 ${env.WORKSPACE}/report

   sh "cp /apps/jenkins/cloudbees-data/jobs/TEST/jobs/all_test/builds/42/htmlreports/HTMLReport ${env.WORKSPACE}/report/"

ERROR :错误 :

   cp: cannot stat ‘/apps/jenkins/cloudbees-data/jobs/DSO_TEST/jobs/dso_automation_ete_test/builds/46/htmlreports/HTMLReport’: No such file or directory

Any Suggestion to copy the HTML publisher report to another path.Not understanding why o could not see an files in the HTMl publisher reported path.将 HTML 发布者报告复制到另一个路径的任何建议。不明白为什么 o 在 HTMl 发布者报告的路径中看不到文件。

You must check if all files are available at the defined location.您必须检查所有文件是否在定义的位置可用。
You can then do a copy command using :然后,您可以使用以下命令执行复制命令:

cp /apps/jenkins/cloudbees-data/jobs/DSO_TEST/jobs/dso_automation_ete_test/builds/46/htmlreports/* ${env.WORKSPACE}/report/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Jenkins 工作区文件夹路径以双引号显示,并且 html-publisher 插件无法检测到 allure-report 文件夹 - Jenkins workspace folder path is shown in double quotes and html-publisher plugin is unable to detect allure-report folder Jenkins 管道中作业 DSL 中的工作区路径 - Workspace path in job DSL within Jenkins pipeline Jenkins 管道发布 html 报告 - Jenkins Pipeline publish html report Pytest: How to update jenkins url in pytest html report instead of local path - Pytest : How to update jenkins url in pytest html report instead of local path Jenkins - 将脚本从本地文件夹复制到工作区 - 错误“无法将参数绑定到参数“路径”,因为它为空” - Jenkins - Copy script from Local folder to Workspace - Error 'Cannot bind argument to parameter 'Path' because it is null' Jenkins Publish HTML 报告不发布 html 报告 - Jenkins Publish HTML report does not publish html reports 无法在 jenking html 报告中看到 css - Unable to see css in jenking html report 詹金斯蓝海工作区路径太长 - Jenkins Blue Ocean workspace Path Too Long 如何使用 HTML 发布者插件在文件夹路径内发布 html 报告? - How to publish html reports inside folder path using HTML publisher plugin? 如何在 Jenkins email 通知中将诱惑或 html 报告作为附件发送 - How to send allure or html report as an attachment in the Jenkins email notifications
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM