You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/logic-apps/set-up-devops-deployment-single-tenant-azure-logic-apps.md
+35-25Lines changed: 35 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,7 +36,7 @@ If you don't have a Standard logic app, you can still follow this guide using th
36
36
37
37
## Deploy infrastructure resources
38
38
39
-
To try the DevOps deployment experience without prior Standard logic app or infrastructure setup, use the following sample projects to deploy an example Standard logic app and infrastructure, based whether you want to use GitHub or Azure DevOps:
39
+
To try the DevOps deployment experience without prior Standard logic app or infrastructure setup, use the following sample projects so you can set up deployment for an example Standard logic app and infrastructure, based whether you want to use GitHub or Azure DevOps:
40
40
41
41
-[GitHub sample for single-tenant Azure Logic Apps](https://github.com/Azure/logicapps/tree/master/github-sample)
42
42
@@ -50,47 +50,57 @@ Both samples include the following resources that a Standard logic app uses to r
50
50
51
51
| Resource name | Required | Description |
52
52
|---------------|----------|-------------|
53
-
| Standard logic app | Yes | This Azure resource contains the workflows that run in single-tenant Azure Logic Apps. |
53
+
| Standard logic app | Yes | This Azure resource contains the workflows that run in single-tenant Azure Logic Apps. <br><br>**Important**: In your logic app project, each workflow has a **workflow.json** file that contains the workflow definition, which includes the trigger and action definitions. |
54
+
| API connections | Yes, if API connections exist | These Azure resources define any managed API connections that your workflows use to run managed connector operations, such as Office 365, SharePoint, and so on. <br><br>**Important**: In your logic app project, the **connections.json** file contains metadata, endpoints, and keys for any managed API connections and Azure functions that your workflows use. To use different connections and functions in each environment, make sure that you parameterize the **connections.json** file and update the endpoints. <br><br>For more information, review [API connection resources and access policies](#api-connection-resources). |
54
55
| Functions Premium or App Service hosting plan | Yes | This Azure resource specifies the hosting resources to use for running your logic app, such as compute, processing, storage, networking, and so on. <br><br>**Important**: In the current experience, the Standard logic app resource requires the [**Workflow Standard** hosting plan](logic-apps-pricing.md#standard-pricing), which is based on the Azure Functions Premium hosting plan. |
55
56
| Azure storage account | Yes, for both stateful and stateless workflows | This Azure resource stores the metadata, keys for access control, state, inputs, outputs, run history, and other information about your workflows. |
56
57
| Application Insights | Optional | This Azure resource provides monitoring capabilities for your workflows. |
57
-
| API connections | Optional, if none exist | These Azure resources define any managed API connections that your workflows use to run managed connector operations, such as Office 365, SharePoint, and so on. <br><br>**Important**: In your logic app project, the **connections.json** file contains metadata, endpoints, and keys for any managed API connections and Azure functions that your workflows use. To use different connections and functions in each environment, make sure that you parameterize the **connections.json** file and update the endpoints. <br><br>For more information, review [API connection resources and access policies](#api-connection-resources). |
58
58
| Azure Resource Manager (ARM) template | Optional | This Azure resource defines a baseline infrastructure deployment that you can reuse or [export](../azure-resource-manager/templates/template-tutorial-export-template.md). |
59
59
60
+
<aname="api-connection-resources"></a>
61
+
62
+
## API connection resources and access policies
63
+
64
+
In single-tenant Azure Logic Apps, every managed API connection resource in your workflow requires an associated access policy. This policy needs your logic app's identity to provide the correct permissions for accessing the managed connector infrastructure. The included sample projects include an ARM template that includes all the necessary infrastructure resources, including these access policies.
65
+
66
+
For example, the following diagram shows the dependencies between a Standard logic app project and infrastructure resources:
67
+
68
+

69
+
60
70
<aname="download-artifacts"></a>
61
71
62
72
## Download Standard logic app artifacts from portal
63
73
64
-
If your Standard logic app is in the Azure portal, you can download and save a zip file that contains your logic app's artifact files, including **workflow.json**, **connections.json**, **host.json**, and **local.settings.json**.
74
+
If your Standard logic app is in the Azure portal, you can download a zip file that contains your logic app's artifact files, including **workflow.json**, **connections.json**, **host.json**, and **local.settings.json**.
65
75
66
76
1. In the [Azure portal](https://portal.azure.com), find and open your Standard logic app resource.
67
77
68
78
1. On the logic app menu, select **Overview**.
69
79
70
80
1. On the **Overview** toolbar, select **Download app content**. In the confirmation box that appears, select **Download**.
71
81
72
-
1. When the prompt appears, select **Save as**, browse to the local folder that you want, and select **Save**.
82
+
1. When the prompt appears, select **Save as**, browse to the local folder that you want, and select **Save** to save the zip file.
73
83
74
84
1. Extract the zip file.
75
85
76
-
<aname="api-connection-resources"></a>
77
-
78
-
## API connection resources and access policies
86
+
1. In Visual Studio Code, open the folder that contains the unzipped files.
79
87
80
-
In single-tenant Azure Logic Apps, every managed API connection resource in your workflow requires an associated access policy. This policy needs your logic app's identity to provide the correct permissions for accessing the managed connector infrastructure. The included sample projects include an ARM template that includes all the necessary infrastructure resources, including these access policies.
88
+
When you open the folder, Visual Studio Code automatically creates a [workspace](https://code.visualstudio.com/docs/editor/workspaces).
81
89
82
-
For example, the following diagram shows the dependencies between a Standard logic app project and infrastructure resources:
90
+
1. Edit the folder's contents to include only the folders and files required for deployment using DevOps.
83
91
84
-

92
+
1. When you finish, save your changes.
85
93
86
94
<aname="deploy-logic-app-resources"></a>
87
95
88
96
## Build and deploy logic app (zip deploy)
89
97
90
-
If you have a Standard logic app project, push that project and artifact files to your source repository. You can then set up build and release pipelines either inside or outside Azure that deploy Standard logic apps to your infrastructure.
98
+
You can set up build and release pipelines either inside or outside Azure that deploy Standard logic apps to your infrastructure.
91
99
92
100
### Build your project
93
101
102
+
1. Push your Standard logic app project and artifact files to your source repository.
103
+
94
104
1. To set up a build pipeline based on your logic app project type, complete the corresponding actions in the following table:
95
105
96
106
| Project type | Description and steps |
@@ -117,11 +127,11 @@ If you have a Standard logic app project, push that project and artifact files t
117
127
> local.settings.json
118
128
> ```
119
129
120
-
### Before release to Azure
130
+
## Before you release to Azure
121
131
122
132
The managed API connections inside your logic app project's **connections.json** file are created specifically for local use in Visual Studio Code. Before you can release your project artifacts from Visual Studio Code to Azure, you have to update these artifacts. To use the managed API connections in Azure, you have to update their authentication methods so that they're in the correct format to use in Azure.
123
133
124
-
#### Update authentication type
134
+
### Update authentication type
125
135
126
136
For each managed API connection that uses authentication, you have to update the **`authentication`** object from the local format in Visual Studio Code to the Azure portal format, as shown by the first and second code examples, respectively:
127
137
@@ -169,7 +179,7 @@ For each managed API connection that uses authentication, you have to update the
169
179
}
170
180
```
171
181
172
-
####Create API connections as needed
182
+
### Create API connections as needed
173
183
174
184
If you're deploying your Standard logic app to an Azure region or subscription different from your local development environment, you must also make sure to create these managed API connections before deployment. Azure Resource Manager template (ARM template) deployment is the easiest way to create managed API connections.
175
185
@@ -227,15 +237,15 @@ In the response, find the **`connectionParameters`** object, which contains the
227
237
228
238
As an alternative, you can capture and review the network trace for when you create a connection using the workflow designer in Azure Logic Apps. Find the **`PUT`** call that is sent to the managed connector's API as previously described, and review the request body for all the necessary information.
229
239
230
-
####On-premises data gateway resource definition
240
+
### On-premises data gateway resource definition
231
241
232
242
If your connection uses an on-premises data gateway resource, this resource definition exists separately from the connector resource definition. To view the data gateway's resource definition, see [Automate deployment for Azure Logic Apps by using Azure Resource Manager templates](logic-apps-azure-resource-manager-templates-overview.md#data-gateway-resource-definitions) and [Microsoft.Web connectionGateways](/azure/templates/microsoft.web/connectiongateways?pivots=deployment-language-arm-template#connectiongatewayreference-1).
233
243
234
-
###Release to Azure
244
+
## Release to Azure
235
245
236
246
To set up a release pipeline that deploys to Azure, follow the associated steps for GitHub, Azure DevOps, or Azure CLI.
237
247
238
-
####[GitHub](#tab/github)
248
+
### [GitHub](#tab/github)
239
249
240
250
For GitHub deployments, you can deploy your logic app by using [GitHub Actions](https://docs.github.com/actions), for example, the GitHub Actions in Azure Functions. This action requires that you pass through the following information:
241
251
@@ -255,7 +265,7 @@ For GitHub deployments, you can deploy your logic app by using [GitHub Actions](
255
265
256
266
For more information, review [Continuous delivery by using GitHub Action](../azure-functions/functions-how-to-github-actions.md).
257
267
258
-
#### [Azure DevOps](#tab/azure-devops)
268
+
### [Azure DevOps](#tab/azure-devops)
259
269
260
270
For Azure DevOps deployments, you can deploy your logic app by using the [Azure Function App Deploy task](/azure/devops/pipelines/tasks/deploy/azure-function-app?view=azure-devops&preserve-view=true) in Azure Pipelines. This action requires that you pass through the following information:
261
271
@@ -276,7 +286,7 @@ For Azure DevOps deployments, you can deploy your logic app by using the [Azure
276
286
277
287
For more information, review [Deploy an Azure Function using Azure Pipelines](/azure/devops/pipelines/targets/azure-functions-windows).
278
288
279
-
#### [Azure CLI](#tab/azure-cli)
289
+
### [Azure CLI](#tab/azure-cli)
280
290
281
291
If you use other deployment tools, you can deploy your Standard logic app by using the Azure CLI. Before you start, you need the following items:
282
292
@@ -307,7 +317,7 @@ If you use other deployment tools, you can deploy your Standard logic app by usi
307
317
308
318
<a name="check-pip-version"></a>
309
319
310
-
##### Check pip installation
320
+
#### Check pip installation
311
321
312
322
1. On a Windows or Mac operating system, open a command prompt, and enter the following command:
313
323
@@ -323,7 +333,7 @@ If you use other deployment tools, you can deploy your Standard logic app by usi
323
333
324
334
<a name="check-environment-cli-version"></a>
325
335
326
-
##### Check environment and CLI version
336
+
#### Check environment and CLI version
327
337
328
338
1. Sign in to the [Azure portal](https://portal.azure.com). In a terminal or command window, confirm that your subscription is active by running the command, [**`az login`**](/cli/azure/authenticate-azure-cli):
329
339
@@ -346,7 +356,7 @@ If you use other deployment tools, you can deploy your Standard logic app by usi
346
356
347
357
<a name="install-logic-apps-cli-extension"></a>
348
358
349
-
##### Install Azure Logic Apps (Standard) extension for Azure CLI
359
+
#### Install Azure Logic Apps (Standard) extension for Azure CLI
350
360
351
361
Currently, only the *preview* version for this extension is available. If you didn't install this extension yet, run the command, **`az extension add`**, with the following required parameters:
352
362
@@ -371,7 +381,7 @@ az extension add --yes --source "https://aka.ms/logicapp-latest-py2.py3-none-any
371
381
372
382
<a name="create-resource-group"></a>
373
383
374
-
##### Create resource group
384
+
#### Create resource group
375
385
376
386
If you don't have an existing Azure resource group to use for deployment, create the group by running the command, **`az group create`**. Unless you already set a default subscription for your Azure account, make sure to use the **`--subscription`** parameter with your subscription name or identifier. Otherwise, you don't have to use the **`--subscription`** parameter.
377
387
@@ -403,7 +413,7 @@ If your resource group is successfully created, the output shows the **`provisio
403
413
404
414
<a name="deploy-logic-app"></a>
405
415
406
-
##### Deploy logic app
416
+
#### Deploy logic app
407
417
408
418
Now, you can deploy your zipped artifacts to the Azure resource group that you created.
0 commit comments