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
+21-8Lines changed: 21 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -153,27 +153,35 @@ 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:
156
+
1. Create the storage account to use forthe web job storage and get it's connection string. Replace `<webjobStorage>` with the name you want to use.
157
157
158
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>
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 `<webjobStorage>`with the name of the storage account from the previous step:
> 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
173
166
-
1. Create the storage account to use as the trigger and get it's connection string.
174
+
1. Create the storage account to use for the blob trigger storage and get it's connection string. Replace `<triggerStorage>` with the name you want to use.
Record this connection string to provide to the function app. We will use it later when we ask for`<triggerConnectionString>`
175
183
176
-
1. Create the containers for the inputand output in the storage account.
184
+
1. Create the containers for the inputand output in the storage account. Replace `<triggerConnectionString>`with the connection string returned earlier:
177
185
178
186
```azurecli-interactive
179
187
az storage container create -n input--connection-string <triggerConnectionString>
@@ -182,12 +190,17 @@ When `show_output=True`, the output of the Docker build process is shown. Once t
182
190
az storage container create -n output --connection-string <triggerConnectionString>
183
191
```
184
192
185
-
1. You will need to retrieve the tag associated with the created container using the following command:
193
+
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:
194
+
195
+
```azurecli-interactive
196
+
az functionapp config appsettings set--name <app-name>--resource-group myresourcegroup --settings "TriggerConnectionString=<triggerConnectionString>"
197
+
```
198
+
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
199
187
200
```azurecli-interactive
188
201
az acr repository show-tags --repository package --name <username>--output tsv
189
202
```
190
-
The most recent tag shown will be `imagetag`below.
203
+
Save the value returned, it will be used as the `imagetag`in the next step.
191
204
192
205
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