我正在将我的 .NET MVC 应用程序移动到 Microsoft Azure 云服务。我计划将配置从 web.config 移动到 azure 中的 csdef/cscfg。
我的 web.config 文件几乎没有自定义配置部分。
<configuration>
<configSections>
<section name="myConfig1" type="MyNamespace.MyClassType" />
</configSections>
<myConfig1 someProperty1="someValue1" someProperty2="someValue2" someProperty3="someValue3">
<test1 testproperty=testValue />
<test2 xProperty=xValue />
</myConfig1>
</configuration>
我在应用程序启动时使用此配置(global.asax)。我想把它转换成csdef/cscfg。通常 cscfg 具有配置设置的键/值对。
谁能建议我如何将自定义配置转换为 azure 中的服务配置?