Set up CD for Standard logic apps with Deployment Center

Applies to: Azure Logic Apps (Standard)

To streamline deployment automation for Standard logic apps, you can directly integrate your source code repository with your logic app resources by using Deployment Center. This capability helps you set up continuous deployment (CD) directly within your logic app, so you can make sure that every change committed to your repository gets automatically deployed to your logic app. Your team can then ship new features, fix bugs, and respond to changes faster, yet maintain control and visibility over the deployment process.

Deployment Center supports multiple source control providers, seamlessly fits into modern DevOps workloads and scenarios, and makes sure that your logic apps stay current and production ready.

Prerequisites

Turn on SCM Basic Auth publishing credentials

  1. In the Azure portal, open your Standard logic app resource.

  2. On the resource sidebar, under Settings, select Configuration.

  3. On the General settings tab, under Platform settings, select SCM Basic Auth Publishing Credentials so that the setting is turned on.

  4. When you're done, select Apply.

The following example shows where to find the SCM Basic Auth Publishing Credentials setting:

Screenshot shows Azure portal, Standard logic app, Configuration page, and selected setting for SCM Basic Auth Publishing Credentials.

Create user-assigned managed identity and assign roles

  1. In the Azure portal, open your Standard logic app resource.

  2. Follow the general steps to create the user-assigned managed identity.

  3. Follow the general steps to add the user-assigned managed identity to your logic app.

  4. Follow the general steps to give the identity access to the resources in the Prerequisites section.

  5. When you're done, continue on to create scripts for Deployment Center.

Generate scripts for Deployment Center

  1. In Visual Studio Code, open the workspace and project for your Standard logic app.

  2. On the Visual Studio Code Activity Bar, select Explorer (files icon) to open the Explorer window, which shows your logic app project and files.

  3. In the Explorer window, find the project root level. Open the project context menu, and select Generate deployment scripts.

    Screenshot shows Visual Studio Code, Standard logic app project with context menu, and selected option to generate deployment scripts.

  4. Follow the prompts to complete the following steps:

    1. Select the Azure subscription for your deployed Standard logic app.

    2. Select the Azure resource group for your logic app, and then select your logic app.

    3. Select the associated user-assigned managed identity that has Logic Apps Standard Contributor role-based access.

    When you're done, Visual Studio Code creates the following folders and files:

    Folder name File name Description
    <logic-app-project-folder-name> cloud.settings.json This file contains the following content:

    - Keys copied from the local.settings.json file and required for logic app deployment.

    - Placeholders to specify the key vault references for any secrets.

    - Any associated nonsecret values.
    deployment deploy.ps1 This deployment script parameterizes the items that you selected during deployment script generation. The script also performs the following tasks:

    - Deploys the logic app code.

    - Updates the authentication required for any Azure-hosted managed connection definition in the connections.json file.

    - Configures the settings defined in the cloud.settings.json file created in your logic app project.
    <logic-app-project-folder-name> README.md This file contains instructions about how to update the cloud.settings.json so you can safely deploy application secrets, for example:

    - Connection strings required for built-in, service provider-based connections in your project.

    - Keys for Azure API Management, Azure Functions, and so on.

    - Keys for any other customer-defined secrets.
  5. Review the created files, and update the cloud.settings.json with your key vault references.

  6. When you're done, push your changes to your source control repository.

Set up Deployment Center with your source repository

To set up Deployment Center with a repository in GitHub for your Standard logic app, follow these steps:

  1. In the Azure portal, open your Standard logic app resource.

  2. On the resource sidebar, under Deployment, select Deployment Center.

  3. From the Source list, select GitHub as your source repository.

  4. Under the Source list, select Change provider, and select App Service Build Service as the build provider.

    Screenshot shows Azure portal, Standard logic app sidebar, Deployment Center page, GitHub as source, and selected App Service Build Service.

  5. In GitHub, sign in, if necessary, and select your organization.

  6. Select your repository, and then select your branch.

  7. When you're done, at the top of the page, select Save.

Confirm successful deployment

To make sure that your deployment works correctly, follow these steps:

  1. Return to your logic app's Deployment Center page, and select the Logs tab.

  2. If necessary, refresh the Logs tab. Review the status message to check that the deployment successfully finished, for example:

    Screenshot shows Azure portal, logic app's Deployment Center page, and selected Logs tab with deployment status.