Set up continuous deployment

APPLIES TO: SDK v4

This article describes how to configure continuous deployment. You can enable continuous deployment to automatically deploy code changes from your source repository to Azure.

This article covers setting up continuous deployment for GitHub. For information on setting up continuous deployment with other source control systems, see continuous deployment to Azure App Service.

Note

The Bot Framework JavaScript, C#, and Python SDKs will continue to be supported, however, the Java SDK is being retired with final long-term support ending in November 2023. Only critical security and bug fixes within this repository will be undertaken.

Existing bots built with the Java SDK will continue to function.

For new bot building, consider using Power Virtual Agents and read about choosing the right chatbot solution.

For more information, see The future of bot building.

Prerequisites

  • If you don't have an Azure subscription, create a free account before you begin.
  • Before setting up continuous deployment, Deploy your bot to Azure at least once.
  • A GitHub account and a repository to use for your bot.

Prepare your GitHub repository

Add your bot project to your GitHub repository.

Important

To enable automatic builds from the build provider, your repository root must contain specific files for your project.

Runtime Root directory files
ASP.NET Core .sln or .csproj
Node.js server.js, app.js, or package.json with a start script
Java pom.xml
Python app.py

Set up continuous deployment with GitHub

  1. Go to the Azure portal.
  2. Open the App Service blade for your bot.
  3. Under Deployment, select Deployment Center to open the Deployment Center blade.
  4. Select the Settings tab.
    1. For Source, select GitHub.

    2. Change the build provider:

      1. Select Change provider.
      2. Select App Service Build Service, then OK.
    3. If you haven't connected to GitHub from Azure before, select Authorize to authorize Azure App Service to access your GitHub account.

    4. Check that the Signed in as field shows your correct GitHub account.

      To sign into and authorize a different account, select Change account.

    5. For Organization, Repository, and Branch, select the GitHub organization, repository, and branch that contains your bot project.

    6. Select Save.

At this point, continuous deployment with GitHub is set up. New commits in the selected repository and branch now deploy continuously into your App Service app. You can track the commits and deployments on the Logs tab.

Screenshot of the Deployment Center blade, with the source and build provider configured.

Disable continuous deployment

While your bot is configured for continuous deployment, you may not use the online code editor to make changes to your bot. If you want to use the online code editor, you can temporarily disable continuous deployment.

To disable continuous deployment:

  1. Go to the Azure portal.
  2. Open the App Service blade for your bot.
  3. Under Deployment, select Deployment Center to open the Deployment Center blade.
  4. Select the Settings tab.
  5. Select Disconnect to disable continuous deployment.

To re-enable continuous deployment, repeat the steps from Set up continuous deployment with GitHub.