Setting the SQL connection string for ASP.NET Core web app in Azure

后端 未结 4 1395
庸人自扰
庸人自扰 2020-12-03 06:36

I have created a new ASP.NET Core web application in Visual Studio 2015. I\'ve also set up an Azure web app to pull in the app from GitHub and run it. This works fine, but I

4条回答
  •  不思量自难忘°
    2020-12-03 07:16

    I think you are looking for SlotSticky Settings

    Use this command in Azure PowerShell to set 2 app settings as sticky to the slot

    Set-AzureWebsite -Name mysite -SlotStickyAppSettingNames @("myslot", "myslot2")
    

    And this command to set 2 connection strings as sticky to the slot

    Set-AzureWebsite -Name mysite -SlotStickyConnectionStringNames @("myconn", "myconn2")
    

提交回复
热议问题