指定deploy.cmd时,Azure KUDU部署会忽略项目设置 [英] Azure KUDU deployment ignores project setting when deploy.cmd is specified

查看:65
本文介绍了指定deploy.cmd时,Azure KUDU部署会忽略项目设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的nodeJS存储库中有一个自定义.deployment文件,如下所示:

I have a custom .deployment file in my nodeJS repo that looks like this:

[config]
project = src/portal
command = deploy.cmd

如果删除command设置,则将遵守project设置.但是,我需要自定义部署脚本来执行一些Bower和Grunt命令.每当我重新添加command参数时,Azure/KUDU似乎都会忽略project设置.我已恢复为使用azure site deploymentscript --node生成的默认deploy.cmd脚本,以确保自定义不是问题.问题仍然存在.我想念什么吗?

If I remove the command setting, the project setting is respected. However, I need the custom deploy script to execute some bower and grunt commands. Whenever I add the command parameter back in, Azure/KUDU seems to ignore the project setting. I have reverted to the default deploy.cmd script generated using azure site deploymentscript --node to ensure that my customizations aren't the issue. The problem remains. Am I missing something?

作为参考,这是天蓝色的KUDU输出:

For reference, here's the KUDU output from azure:

remote: Updating branch 'master'.
remote: Updating submodules.
remote: Preparing deployment for commit id '3f92585db0'.
remote: Running custom deployment command...
remote: Running deployment command...
remote: Handling node.js deployment.
remote: KuduSync.NET from: 'D:\home\site\repository' to: 'D:\home\site\wwwroot'
remote: Looking for app.js/server.js under site root.
remote: Missing server.js/app.js files, web.config is not generated
remote: The package.json file does not specify node.js engine version  constraints.
remote: The node.js application will run with the default node.js version 0.10.32.
remote: Finished successfully.
remote: Deployment successful.

推荐答案

这是设计使然,当您具有自定义部署脚本时,您可以完全控制部署,因此具有project属性没有任何意义.

This is by design, when you have a custom deployment script you have full control over the deployment and so the project property has no meaning.

如果您需要其他项目,只需使用所需的内容更新自定义部署脚本即可.

If you need a different project simply update the custom deployment script with what you need.

这篇关于指定deploy.cmd时,Azure KUDU部署会忽略项目设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆