Windows Azure的与多个站点中的一个角色不改变第二web.debug.config到的web.config [英] Windows Azure with Multiple Sites in One Role not transforming 2nd web.debug.config to web.config

查看:113
本文介绍了Windows Azure的与多个站点中的一个角色不改变第二web.debug.config到的web.config的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的Web.Config变换部署我的应用程序的Azure。我也有我的服务,公共网站和私人网站的WCF端点2点。我部署<一个href=\"http://www.wadewegner.com/2011/02/running-multiple-websites-in-a-windows-azure-web-role/\">multiple网站给一个角色。

I am using Web.Config transformations to deploy my application to Azure. I also have 2 sites in my service, a public website, and private WCF site endpoint. I am deploying multiple sites to a single role.

当我部署,该网站项目(为其Azure的部署项目设置)正确转换的web.config文件。但是,WCF项目(只针对作为.csdef文件中的网站)的web.debug.config文件不变换的web.config。

When I deploy, the website project (for which the Azure Deploy project is set) transforms the web.config correctly. However, the WCF project (which is only addressed as a "site" in the .csdef file) does not transform the web.debug.config file to web.config.

<一个href=\"http://stackoverflow.com/questions/5134875/azure-multiple-web-sites-with-one-role-but-some-dont-get-rebuilt-when-i-publish\">This问题是相似的,但只是解决了项目建设。我已经在我的项目设置的依赖关系。

This question is similar, but only addresses the projects building. I have set the dependencies in my project.

<一个href=\"http://stackoverflow.com/questions/6181917/azure-multiple-sites-on-1-role-physical-directory-post-build-event\">This解决方法强制转换的web.config文件,但它仍然没有出现在我在Azure上的部署。

This workaround forces the transform of the web.config file, but it still does not appear in my deployment on Azure.

我怀疑<一个href=\"http://connect.microsoft.com/VisualStudio/feedback/details/641913/visual-studio-azure-tools-sdk-1-3-not-packaging-multiple-sites-correctly\">this错误依然存在,我也升级到的Azure SDK 1.5 在希望它会解决它。

I suspect that this bug still exists, and I have also upgraded to the Azure 1.5 SDK in hopes that it will fix it.

我想尝试把我的配置数据cscfg文件但我使用实体框架code首先,我不知道如何让我的连接字符串这种格式工作。 EFCF似乎依靠web.config中作了明确规定。

I would like to try putting my configuration data in cscfg files but I am using Entity Framework Code First, and I do not know how to get my connection string to work with this format. EFCF seems to rely on web.config explicitly.

任何帮助将是AP preciated。

Any help would be appreciated.

推荐答案

当您添加另一个Web角色,您提供的physicalPath指向你想要的部署,所有的SDK确实是找到的文件复制在这条道路进入你的包。它没有做一个构建。

When you add another web role, you provide a physicalPath to point to what you want deployed, and all the SDK does is copy the files it finds at that path into your package. It doesn't do a build.

您或许应该做一个构建和发布要部署Web应用程序,然后在输出的指向是发布步骤physicalDirectory。 (请确保您在physicalDirectory设置目录包含要部署到云到底是什么。)

You should probably be doing a build and a publish of the web app you want to deploy, and then point the physicalDirectory at the output of that publish step. (Make sure the directory you're setting in physicalDirectory contains exactly what you want to have deployed to the cloud.)

这篇关于Windows Azure的与多个站点中的一个角色不改变第二web.debug.config到的web.config的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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