安裝 Visual Studio,鏈接中國區 Azure

中國數據中心

目前,中國區 Azure 有兩個數據中心,在位置字段中顯示爲「中國北部」和「中國東部」。nginx

在 Azure 上建立應用程序的區別

在中國區 Azure 上開發應用程序與在境外 Azure 上開發的主要區別在於,中國區 Azure 端點地址有不一樣的 URI。 例如,Azure 和 SQL 數據庫 URI 一般以 windows.net 結尾。 URI 端點不一樣時,開發人員必須可以識別,而後配置所需的工具和應用程序,並使用適合的 URI。數據庫

 

世紀互聯運營的Azure帳號,默認沒辦法登陸。windows

安裝 Visual Studio,鏈接中國區 Azure

步驟以下:api

  1. 請使用如下注冊表文件:瀏覽器

    Azure.reg工具

        Windows Registry Editor Version 5.00

        [HKEY_CURRENT_USER\Software\Microsoft\VSCommon\ConnectedUser]
        "AadInstance"="https://login.chinacloudapi.cn/"
        "adaluri"="https://management.core.chinacloudapi.cn"
        "AzureRMEndpoint"="https://management.chinacloudapi.cn"
        "AzureRMAudienceEndpoint"="https://management.core.chinacloudapi.cn"
        "EnableAzureRMIdentity"="true"
        "GraphUrl"="graph.chinacloudapi.cn"

    若要將 Reg 值返回境外 Azure,請使用此處的註冊表文件:spa

    TargetProduction.reg.net

        Windows Registry Editor Version 5.00

        [HKEY_CURRENT_USER\Software\Microsoft\VSCommon\ConnectedUser]
        "Uri"=-
        "AadInstance"=-
        "adaluri"=-
        "AzureRMEndpoint"=-
        "AzureRMAudienceEndpoint"=-
        "EnableAzureRMIdentity"=-
        "GraphUrl"=-
        "AadApplicationTenant"=-

        [HKEY_CURRENT_USER\SOFTWARE\Microsoft\VisualStudio\14.0\MicrosoftAzureServices]
        "Resource Management Audience Endpoint"=-
        "Service Management Endpoint"=-
  2. 雙擊 Azure.reg 文件,贊成彈出信息,容許註冊表值更改;code

  3. 註冊表值更改後,Visual Studio 的登陸信息鏈接到中國區 Azure 服務。blog

實用場景示例

雲瀏覽器

  1. 按照說明輸入認證信息;

    01

  2. 輸入登陸信息;

    02

  3. 從 Cloud Explorer 查看中國區 Azure 訂閱中的資源。

    03

發佈 Web 應用程序

  1. 單機右鍵菜單,選擇 「發佈」 對話框;

    04

  2. 選擇 Microsoft Azure App Service;

    05

  3. 從賬戶選擇器中選擇 Azure 賬戶;

    060708

Azure 資源管理器工具

  1. 單機右鍵菜單,選擇 「部署」 對話框;

    09

  2. 從賬戶選擇器中選擇 Azure 賬戶;

    10

  3. 對於在資源模板中出現、但中國區 Azure 不支持的資源,該界面會發出警告;

    11

  4. 編輯模板參數,繼續部署。

其餘功能的步驟與此相似。

相關文章
相關標籤/搜索