通过代码将域添加到 Azure 网站

Add a domain to an Azure web site via code(通过代码将域添加到 Azure 网站)
本文介绍了通过代码将域添加到 Azure 网站的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何以编程方式将其他域名添加到 Azure 网站?

How do I programmatically add an additional domain name to an Azure Web Site?

希望有我错过的 .NET API,可能在 Azure SDK 或 NuGet 包中.或者也许有一个 REST 接口.

Hopefully there .NET API for this that I missed, perhaps in the Azure SDK or a NuGet package. Or perhaps there is a REST interface.

推荐答案

Windows Azure 网站管理 REST API 应该提供您正在寻找的功能.

The Windows Azure Web Sites Management REST API should provide the functionality you are looking for.

Windows Azure 网站的Site.HostNames 属性可用于提供额外的域名.这些属性可以在网站创建期间或更新时提供.

The property Site.HostNames property of Windows Azure Web Site can be used to provide additional domain names. The properties can be provided during creation of a web site or when updating.

还请注意 为 Windows Azure 网站配置自定义域名.您还必须以编程方式将验证条目添加到您的 DNS.

Please also take note of the general info on Configuring a custom domain name for a Windows Azure web site. You would also have to programmatically add the verification entry to your DNS.

我不确定网站管理 API 是否有任何包装 SDK/libs/powershell 命令行开关.

I am not sure if there are any wrapper SDKs/libs/powershell commandlets for the web sites management API.

这篇关于通过代码将域添加到 Azure 网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

c# Generic Setlt;Tgt; implementation to access objects by type(按类型访问对象的C#泛型集实现)
InvalidOperationException When using Context Injection in ASP.Net Core(在ASP.NET核心中使用上下文注入时发生InvalidOperationException)
dropbox-sdk-dotnet: how to get a refresh token and update the access token(Dropbox-SDK-Dotnet:如何获取刷新令牌并更新访问令牌)
quot;Overflowquot; compiler error with -9223372036854775808L(编译器错误-9223372036854775808L(Q;溢出Q))
Visual Studio 2010 ReportViewer Assembly References(Visual Studio 2010 ReportViewer程序集引用)
Weird behaviour when I open a reportviewer in WPF(在WPF中打开报表查看器时出现奇怪的行为)