问题描述
当我将deploy.sh文件部署到azure时,我收到此错误。我如何解决这个问题?
命令:bash deploy.sh
处理node.js部署。
KuduSync.NET从:'D:\home\site\repository\\\
odejs'到:'D:\home\site\wwwroot'
错误:找不到路径D:\home\site\repository\\\
odejs的一部分。
网站部署期间发生错误。
Kudu同步失败
错误:找不到路径的一部分'D:\home\site\repository\\\
odejs'.\r\\\
D:\Program Files( x86)\SiteExtensions\Kudu\59.51202.2583\bin\Scripts\starter.cmd bash deploy.sh
我的网站使用NodeJS作为taskrunner,但构建脚本在甚至到达构建部分之前就会失败。
这是失败的代码:
if [[$ IN_PLACE_DEPLOYMENT-ne1]];然后
$ KUDU_SYNC_CMD-v 50 -f$ DEPLOYMENT_SOURCE / nodejs-t$ DEPLOYMENT_TARGET-n$ NEXT_MANIFEST_PATH-p$ PREVIOUS_MANIFEST_PATH-i.git; .hg; .deployment; deploy.sh
exitWithMessageOnErrorKudu同步失败
fi
m在mac上,失败的代码由azure-cli包生成。
错误指示, p>
所以请将$ DEPLOYMENT_SOURCE / nodejs
更改为$ DEPLOYMENT_SOURCE
并重新部署。
或者,您可以重新生成 deploy.sh
文件,在Azure CLI中使用以下命令,
azure site deploymentscript --node -t bash
I get this error when I deploy my deploy.sh file to azure.How can I fix this ?
Command: bash deploy.sh
Handling node.js deployment.
KuduSync.NET from: 'D:\home\site\repository\nodejs' to: 'D:\home\site\wwwroot'
Error: Could not find a part of the path 'D:\home\site\repository\nodejs'.
An error has occurred during web site deployment.
Kudu Sync failed
Error: Could not find a part of the path 'D:\home\site\repository\nodejs'.\r\nD:\Program Files (x86)\SiteExtensions\Kudu\59.51202.2583\bin\Scripts\starter.cmd bash deploy.sh
My website is using NodeJS as taskrunner, but the build scripts fails before it even reaches the build part.
This is the code that fails:
if [[ "$IN_PLACE_DEPLOYMENT" -ne "1" ]]; then
"$KUDU_SYNC_CMD" -v 50 -f "$DEPLOYMENT_SOURCE/nodejs" -t "$DEPLOYMENT_TARGET" -n "$NEXT_MANIFEST_PATH" -p "$PREVIOUS_MANIFEST_PATH" -i ".git;.hg;.deployment;deploy.sh"
exitWithMessageOnError "Kudu Sync failed"
fi
I'm on a mac and the the code that fails was generated by the azure-cli package.
The error indicates,
So please change "$DEPLOYMENT_SOURCE/nodejs"
to "$DEPLOYMENT_SOURCE"
and redeploy it.
Or you can regenerate the deploy.sh
file with the command below in Azure CLI,
azure site deploymentscript --node -t bash
这篇关于当我尝试通过GitHub部署时,Azure失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!