What parameters are showing undefined in this dnvm.ps1 command? Deployment to Azure Web Site Fails as a result

感情迁移 提交于 2019-12-07 16:48:53

问题


I have been developing a new ASP.NET 5 (MVC 6) website on Linux.

I am using Git with Azure and have been able to successfully push it to SCM. However my deployment fails due to some undefined parameters.

Hoping someone can tell me what the undefined parameters are in the command shown in the terminal output so I can modify the script and finish this process.

I run the command

# git push azure master

The following is the output, auto deployment should happen after a successful commit.

The commit works but when it tries to run the following command it fails.

dnvm.ps1' " install undefined -arch undefined -r undefined

I believe this is in the Deploy.cmd file generated by

#  azure site deploymentscript mysite --aspNet5 project.json 

that is triggered after a successful commit


回答1:


when you generate your deploy.cmd you need to pass in the version, arch, and CLR or CoreCLR

azure site deploymentscript mysite --aspNet5 project.json --aspNet5Version <version> --aspNet5Runtime <CLR|CoreCLR> --aspNet5Architecture <x64|x86>

so for example for 1.0.0-rc1-final running on a 32 bit CoreCLR you'll need

azure site deploymentscript mysite --aspNet5 project.json --aspNet5Version 1.0.0-rc1-final --aspNet5Runtime CoreCLR --aspNet5Architecture x86

It's a bug that the generator allows that to happen in the first place. I haven't had the time to fix it, but feel free to open an issue https://github.com/projectkudu/KuduScript/issues but as I understand things are going to change with RC2 so I was waiting for that.

Also keep in mind that azure should auto generate the right deploy.cmd if you don't have it there. You really only need to generate it yourself if there is some special logic that you need there that won't be a part of the auto generated one.



来源:https://stackoverflow.com/questions/34425789/what-parameters-are-showing-undefined-in-this-dnvm-ps1-command-deployment-to-az

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!