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/container-instances/container-instances-tutorial-azure-function-trigger.md
+5-6Lines changed: 5 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -60,9 +60,9 @@ az functionapp identity assign \
60
60
--role contributor --scope $rgID
61
61
```
62
62
63
-
## Update HttpTrigger function
63
+
## Modify HttpTrigger function
64
64
65
-
Update the PowerShell code for the **HttpTrigger** function to create a container group. In file `run.ps1` for the function, find the following code block. This code displays a name value, if one is passed as a query string in the function URL:
65
+
Modify the PowerShell code for the **HttpTrigger** function to create a container group. In file `run.ps1` for the function, find the following code block. This code displays a name value, if one is passed as a query string in the function URL:
66
66
67
67
```powershell
68
68
[...]
@@ -92,7 +92,7 @@ This example creates a container group consisting of a single container instance
92
92
93
93
## Test function app locally
94
94
95
-
Ensure that the function runs properly locally before republishing the function app project to Azure. As in the [PowerShell quickstart](../azure-functions/functions-create-first-function-powershell.md), insert a local breakpoint in the PowerShell script and a `Wait-Debugger` call above it. For debugging guidance, see [Debug PowerShell Azure Functions locally](../azure-functions/functions-debug-powershell-local.md).
95
+
Ensure that the function runs properly locally before republishing the function app project to Azure. As shown in the [PowerShell quickstart](../azure-functions/functions-create-first-function-powershell.md), insert a local breakpoint in the PowerShell script and a `Wait-Debugger` call above it. For debugging guidance, see [Debug PowerShell Azure Functions locally](../azure-functions/functions-debug-powershell-local.md).
As a first test, run the `curl` command and pass the function URL without appending a `name` query string.
123
+
As a first test, run the `curl` command and pass the function URL without appending a `name` query string. Make sure to include your function's unique code.
@@ -145,7 +145,7 @@ The function returns status code 400 and the text `Please pass a name on the que
145
145
Please pass a name on the query string or in the request body.
146
146
```
147
147
148
-
### Run function and pass a name of a container group
148
+
### Run function and pass the name of a container group
149
149
150
150
Now run the `curl` command by appending the name of a container group (*mycontainergroup*) as a query string `&name=mycontainergroup`:
151
151
@@ -185,7 +185,6 @@ Sample output:
185
185
Hello from an Azure container instance triggered by an Azure function
186
186
```
187
187
188
-
189
188
## Clean up resources
190
189
191
190
If you no longer need any of the resources you created in this tutorial, you can execute the [az group delete][az-group-delete] command to remove the resource group and all resources it contains. This command deletes the container registry you created, as well as the running container, and all related resources.
0 commit comments