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/machine-learning/how-to-deploy-functions.md
+18-14Lines changed: 18 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -153,17 +153,7 @@ When `show_output=True`, the output of the Docker build process is shown. Once t
153
153
> [!IMPORTANT]
154
154
> Images created by Azure Machine Learning use Linux, so you must use the `--is-linux` parameter.
155
155
156
-
1. To create the function app, use the following command. Replace `<app-name>`with the name you want to use. Replace `<acrinstance>`and`<imagename>`with the values from returned `package.location` earlier:
157
-
158
-
```azurecli-interactive
159
-
az storage account create --name
160
-
az functionapp create --resource-group myresourcegroup --plan myplanname --name <app-name>--deployment-container-image-name <acrinstance>.azurecr.io/package:<imagename>
161
-
```
162
-
163
-
> [!IMPORTANT]
164
-
> At this point, the function app has been created. However, since you haven't provided the connection string for the blob trigger or credentials to the Azure Container Registry that contains the image, the function app is not active. In the next steps, you provide the connection string and the authentication information for the container registry.
165
-
166
-
1. Create the storage account to use as the trigger and get it's connection string.
156
+
1. Create the storage account to use as the trigger and get it's connection string. Replace `<triggerStorage>` with the name you want to use.
@@ -173,7 +163,16 @@ When `show_output=True`, the output of the Docker build process is shown. Once t
173
163
```
174
164
Record this connection string to provide to the function app. We will use it later when we ask for`<triggerConnectionString>`
175
165
176
-
1. Create the containers for the inputand output in the storage account.
166
+
1. To create the function app, use the following command. Replace `<app-name>`with the name you want to use. Replace `<acrinstance>`and`<imagename>`with the values from returned `package.location` earlier. Replace Replace `<triggerStorage>`with the name of the storage account:
> At this point, the function app has been created. However, since you haven't provided the connection string for the blob trigger or credentials to the Azure Container Registry that contains the image, the function app is not active. In the next steps, you provide the connection string and the authentication information for the container registry.
174
+
175
+
1. Create the containers for the inputand output in the storage account. Replace `<triggerConnectionString>`with the connection string returned earlier:
177
176
178
177
```azurecli-interactive
179
178
az storage container create -n input--connection-string <triggerConnectionString>
@@ -182,12 +181,17 @@ When `show_output=True`, the output of the Docker build process is shown. Once t
182
181
az storage container create -n output --connection-string <triggerConnectionString>
183
182
```
184
183
185
-
1. You will need to retrieve the tag associated with the created container using the following command:
184
+
1. To associate the trigger connection string with the function app, use the following command. Replace `<app-name>`with the name of the function app. Replace `<triggerConnectionString>`with the connection string returned earlier:
185
+
186
+
```azurecli-interactive
187
+
az functionapp config appsettings set--name <app-name>--resource-group myresourcegroup --settings "TriggerConnectionString=<triggerConnectionString>"
188
+
```
189
+
1. You will need to retrieve the tag associated with the created container using the following command. Replace `<username>`with the username returned earlier from the container registry:
186
190
187
191
```azurecli-interactive
188
192
az acr repository show-tags --repository package --name <username>--output tsv
189
193
```
190
-
The most recent tag shown will be `imagetag`below.
194
+
Save the value returned, it will be used as the `imagetag`in the next step.
191
195
192
196
1. To provide the function app with the credentials needed to access the container registry, use the following command. Replace `<app-name>`with the name you want to use. Replace `<acrinstance>`and`<imagetag>`with the values from the AZCLI call in the previous step. Replace `<username>`and`<password>`with the ACR login information retrieved earlier:
0 commit comments