Skip to content

Commit b0c62c0

Browse files
committed
Link fixes
1 parent ebac4b9 commit b0c62c0

8 files changed

+125
-80
lines changed

articles/azure-functions/functions-deploy-container-apps.md

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Create your first containerized Azure Functions on Azure Container Apps
33
description: Get started with Azure Functions on Azure Container Apps by deploying your first function app from a Linux image in a container registry.
4-
ms.date: 05/06/2024
4+
ms.date: 07/20/2024
55
ms.topic: quickstart
66
ms.custom: build-2023, devx-track-azurecli, devx-track-extended-java, devx-track-js, devx-track-python, linux-related-content, build-2024, devx-track-ts
77
zone_pivot_groups: programming-languages-set-functions
@@ -62,7 +62,7 @@ Use the following commands to create these items.
6262
```azurecli
6363
az containerapp env create --name MyContainerappEnvironment --enable-workload-profiles --resource-group AzureFunctionsContainers-rg --location eastus
6464
```
65-
This command can take up to 10 minutes to complete.
65+
This command can take a few minutes to complete.
6666
6767
1. Create a general-purpose storage account in your resource group and region.
6868
@@ -74,56 +74,55 @@ Use the following commands to create these items.
7474
7575
In the previous example, replace `<STORAGE_NAME>` with a name that is appropriate to you and unique in Azure Storage. Storage names must contain 3 to 24 characters numbers and lowercase letters only. `Standard_LRS` specifies a general-purpose account [supported by Functions](storage-considerations.md#storage-account-requirements).
7676
77-
1. Before you proceed, use this command to verify that your environment is ready.
78-
79-
```azurecli
80-
az containerapp env show -n MyContainerappEnvironment -g AzureFunctionsContainers-rg
81-
```
82-
8377
## Create and configure a function app on Azure with the image
8478
8579
A function app on Azure manages the execution of your functions in your Azure Container Apps environment. In this section, you use the Azure resources from the previous section to create a function app from an image in a container registry in a Container Apps environment. You also configure the new environment with a connection string to the required Azure Storage account.
8680
8781
Use the [`az functionapp create`](/cli/azure/functionapp#az-functionapp-create) command to create a function app in the new managed environment backed by Azure Container Apps:
8882
89-
# [Azure Container Registry](#tab/acr)
83+
### [Azure Container Registry](#tab/acr)
9084
::: zone pivot="programming-language-csharp"
9185
```azurecli
92-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime dotnet-isolated --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
86+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime dotnet-isolated --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
9387
```
9488
::: zone-end
9589
::: zone pivot="programming-language-javascript"
96-
```console
97-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime node --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
90+
```azurecli
91+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime node --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
9892
```
9993
::: zone-end
10094
::: zone pivot="programming-language-java"
101-
```console
102-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime java --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
95+
```azurecli
96+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime java --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
10397
```
10498
::: zone-end
10599
::: zone pivot="programming-language-powershell"
106-
```console
107-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime powershell --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
100+
```azurecli
101+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime powershell --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
108102
```
109103
::: zone-end
110104
::: zone pivot="programming-language-python"
111-
```console
112-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime python --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
105+
```azurecli
106+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime python --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
113107
```
114108
::: zone-end
115109
::: zone pivot="programming-language-typescript"
116-
```console
117-
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime node --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --registry-server <LOGIN_SERVER> --registry-username <REGISTRY_NAME> --registry-password <ADMIN_PASSWORD>
110+
```azurecli
111+
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime node --image <LOGIN_SERVER>/azurefunctionsimage:v1.0.0 --assign-identity
118112
```
119113
::: zone-end
120114

121-
In the [`az functionapp create`](/cli/azure/functionapp#az-functionapp-create) command, the `--environment` parameter specifies the Container Apps environment and the `--image` parameter specifies the image to use for the function app. In this example, replace `<STORAGE_NAME>` with the name you used in the previous section for the storage account. Also, replace `<APP_NAME>` with a globally unique name appropriate to you, `<LOGIN_SERVER>` with your fully qualified Container Registry server, `<REGISTRY_NAME>` with your registry name for the account, and `<ADMIN_PASSWORD>` with the password to your admin account.
115+
In the [`az functionapp create`](/cli/azure/functionapp#az-functionapp-create) command, the `--environment` parameter specifies the Container Apps environment and the `--image` parameter specifies the image to use for the function app. In this example, replace `<STORAGE_NAME>` with the name you used in the previous section for the storage account. Also, replace `<APP_NAME>` with a globally unique name appropriate to you and `<LOGIN_SERVER>` with your fully qualified Container Registry server.
116+
117+
To use a system-assigned managed identity to access the container registry, you need to enable managed identities in your app and grant the system-assigned managed identity access to the container registry. This example uses `az functionapp identity assign` and `az role assignment create` command to enable managed identities in the app and assign the system-assigned identity to the `ACRPull` role in the container registry:
122118

123-
> [!IMPORTANT]
124-
> The admin account username and password are important credentials. Make sure to store them securely and never in an accessible location like a public repository.
119+
```azurecli
120+
FUNCTION_APP_ID=$(az functionapp identity assign --name glengatestaca-py --resource-group AzureFunctionsContainers-rg --query principalId --output tsv)
121+
ACR_ID=$(az acr show --name glengatest --query id --output tsv)
122+
az role assignment create --assignee $FUNCTION_APP_ID --role AcrPull --scope $ACR_ID
123+
```
125124

126-
# [Docker Hub](#tab/docker)
125+
### [Docker Hub](#tab/docker)
127126
::: zone pivot="programming-language-csharp"
128127
```azurecli
129128
az functionapp create --name <APP_NAME> --storage-account <STORAGE_NAME> --environment MyContainerappEnvironment --workload-profile-name "Consumption" --resource-group AzureFunctionsContainers-rg --functions-version 4 --runtime dotnet-isolated --image <DOCKER_ID>/azurefunctionsimage:v1.0.0

articles/azure-functions/functions-develop-vs-code.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ When you create a function app in Azure, you can choose either a quick function
310310

311311
#### [Advanced options](#tab/advanced-options)
312312

313-
You can't use the [quick create](#quick-function-app-create) if you want more control over the function app that gets created, such as using an existing resouce group, storage account, or Application Insights intance. These steps create a function app with the ability to use existing Azure resources:
313+
You can't use the [quick create](functions-develop-vs-code.md?tabs=quick-create#publish-to-azure) if you want more control over the function app that gets created, such as using an existing resouce group, storage account, or Application Insights intance. These steps create a function app with the ability to use existing Azure resources:
314314

315315
1. In the command palette, enter **Azure Functions: Create function app in Azure...(Advanced)**.
316316

@@ -383,7 +383,7 @@ The create process depends on whether you choose a quick create or you need to u
383383
For more information about the resources required to run your containerized functions in Container Apps, see [Required resources](functions-infrastructure-as-code.md?pivots=container-apps#required-resources).
384384

385385
>[!NOTE]
386-
>You can't currently deploy a containerized function app to an Azure Functions-integrated Container Apps environment. You must publish your container image to a container registry and then set that image in the registry as the deployment source for your Container Apps-hosted function app. For more information, see [Create your function app in a container](functions-how-to-custom-container.md#create-your-function-app-in-a-container) and [Update an image in the registry](functions-how-to-custom-container.md#update-an-image-in-the-registry).
386+
>You can't currently use Visual Studio Code to deploy a containerized function app to an Azure Functions-integrated Container Apps environment. You must instead publish your container image to a container registry and then set that registry image as the deployment source for your Container Apps-hosted function app. For more information, see [Create your function app in a container](functions-how-to-custom-container.md#create-your-function-app-in-a-container) and [Update an image in the registry](functions-how-to-custom-container.md#update-an-image-in-the-registry).
387387
388388
## <a name="republish-project-files"></a>Deploy project files
389389

articles/azure-functions/functions-how-to-custom-container.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ You should also consider [enabling continuous deployment](#enable-continuous-dep
150150
:::zone pivot="azure-functions"
151151
## Azure portal create using containers
152152

153-
When you create a function app in the [Azure portal], you can choose to deploy the function app from an image in a container registry. To learn how to create a containerized function app in a container registry, see [Creating your function app in a container](#creating-your-function-app-in-a-container).
153+
When you create a function app in the [Azure portal], you can choose to deploy the function app from an image in a container registry. To learn how to create a containerized function app in a container registry, see [Create your function app in a container](#create-your-function-app-in-a-container).
154154

155155
The following steps create and deploy an existing containerized function app from a container registry.
156156

@@ -190,7 +190,7 @@ The following steps create and deploy an existing containerized function app fro
190190
:::zone pivot="container-apps"
191191
## Azure portal create using containers
192192

193-
When you create a function app in the [Azure portal], you can choose to deploy the function app from an image in a container registry. To learn how to create a containerized function app in a container registry, see [Creating your function app in a container](#creating-your-function-app-in-a-container).
193+
When you create a function app in the [Azure portal], you can choose to deploy the function app from an image in a container registry. To learn how to create a containerized function app in a container registry, see [Create your function app in a container](#create-your-function-app-in-a-container).
194194

195195
The following steps create and deploy an existing containerized function app from a container registry.
196196

0 commit comments

Comments
 (0)