建立Windows Azure服务时路径过长的错误

问题描述:

我一直试图将我的服务发布到Windows Azure.该服务仅包含一个webRole,但是我添加了远程登录功能,并将其发布并构建了几次,现在突然无法构建.给出的原因是

I have been trying to publish my service to windows azure. The service consists of a single webRole, however I have added remote login functionality published it and built it a few times, and now all the sudden it will not build. The reason it gives is that

以下详细信息:
错误56指定的路径,文件名或两者都太长.完全限定的文件名必须少于260个字符,目录名称必须少于248个字符.C:\ Program Files(x86) \ MSBuild \ Microsoft \ Cloud Service \ 1.0 \ Visual Studio 10.0 \ Microsoft.CloudService.targets 202 5 FileSystemCreator"

Details below:
"Error 56 The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters. C:\Program Files (x86)\MSBuild\Microsoft\Cloud Service\1.0\Visual Studio 10.0\Microsoft.CloudService.targets 202 5 FileSystemCreator"

我参加了所有论坛,使用CSPack命令行打包了服务,这很好,但是我很难为远程桌面连接配置证书,我想利用此功能当我在onStart事件中创建一些网站时,我想探究IIS.一些Microsoft员工确实同意这是一个错误,并已承诺解决此问题,请参考

I have gone on all the forums, I have used CSPack command line for packaging the service which is fine but I'm having a really hard time configuring the certificate for remote desktop connect and I would like to take advantage of this feature as I am creating some websites in the onStart event and I would like to peek into IIS. Some microsoft employees do agree that this is a bug and the have promised a fix this issue, refer to post . I am using VS2010 and I do not know how to fix this bug.

任何人都可以帮忙,或将我指向可以得到任何帮助的地方.

Can anyone please help, or point me to a place where I can get any help.

我在使用新解决方案时遇到了同样的问题.

I ran into the same problem with a new solution.

请注意,与Eugenio Pace的响应不同,该错误仅在部署到Azure时发生(而不是在Azure Compute Emulator中运行项目时发生).

Note that, unlike Eugenio Pace's response suggests, the error occurs only when deploying to Azure (and not when running the project in the Azure Compute Emulator).

尝试将以下行添加到Windows Azure Visual Studio Project文件(* .ccproj)的第一个属性组:

Try adding the following line to the first property group of your Windows Azure Visual Studio Project file (*.ccproj):

<ServiceOutputDirectory>C:\Azure\</ServiceOutputDirectory>

尾部斜杠(对于您选择的任何路径)似乎都是必需的.每次创建软件包时,此文件夹都会被删除.

The trailing slash (for whatever path you select) appears to be required. This folder will be deleted each time you create a package if it exists.

此设置似乎将软件包的工作文件夹重定向到较短的基本路径,从而防止了路径过长的错误.

This setting seems to redirect the working folder for the package to a shorter base path, preventing the path too long error.

信用证转到: http://govada.blogspot.com/2011/12/windows-azure-package-build-error.html