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/azure-web-pubsub/howto-integrate-app-gateway.md
+9-5Lines changed: 9 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,15 +15,15 @@ In this guide, we demonstrate how you can use Azure Application Gateway to secur
15
15
16
16
As illustrated in the diagram, you need to set up a Private Endpoint for your Web PubSub resource. This Private Endpoint needs to be in the same Virtual Network as your Application Gateway.
17
17
18
-
:::image type="content" source="media/howto-integrate-app-gateway/overview.jpg" alt-text="Achitecture overview of using Web PubSub with Azure Application Gateway.":::
18
+
:::image type="content" source="media/howto-integrate-app-gateway/overview.jpg" alt-text="Diagram showing the architecture overview of using Web PubSub with Azure Application Gateway.":::
19
19
20
20
This guide takes a step-by-step approach. First, we configure Application Gateway so that the traffic to your Web PubSub resource can be successfully proxied through. Second, we apply the access control features of Web PubSub to allow traffic from Application Gateway only.
21
21
22
22
23
23
## Step 1: configure Application Gateway to proxy traffic to Web PubSub resource
24
24
The diagram illustrates what we are going to achieve in step 1.
25
25
26
-
:::image type="content" source="media/howto-integrate-app-gateway/overview-step-1.jpg" alt-text="Architecture overview of step 1: configure Application Gateway to proxy traffic Web PubSub resource.":::
26
+
:::image type="content" source="media/howto-integrate-app-gateway/overview-step-1.jpg" alt-text="Diagram showing the architecture overview of step 1: configure Application Gateway to proxy traffic Web PubSub resource.":::
27
27
28
28
### Create an Azure Application Gateway instance
29
29
On Azure portal, search for Azure Application Gateway and follow the steps to create a resource. Key steps are highlighted in the diagram.
@@ -66,7 +66,7 @@ When the three components are configured, you should see something like the scre
66
66
2. Application Gateway routes traffic by consulting the user-configured routing rules.
67
67
3. When the routing rule matches, the traffic is directed to the designated backend target.
68
68
69
-
:::image type="content" source="media/howto-integrate-app-gateway/create-resource-step-7.jpg" alt-text="Create an Application Gateway resource - finished":::
69
+
:::image type="content" source="media/howto-integrate-app-gateway/create-resource-step-7.jpg" alt-text="Create an Application Gateway resource - finished.":::
70
70
71
71
One thing that is worth highlighting is that you configure **non-WebSocket** connections exactly the same way. You can learn more about [Application Gateway's native support for proxying WebSocket connections](../application-gateway/features.md)
72
72
@@ -240,7 +240,7 @@ Three points to note.
240
240
241
241
Open your browser and visit `http://localhost:3000` again, you can verify that the WebSocket is successfully proxied through Application Gateway and receives messages from Application Gateway roughly every 2 seconds.
242
242
243
-
:::image type="content" source="media/howto-integrate-app-gateway/local-browser-client-indirect.jpg" alt-text="Screenshot of a browser client indirectly connected with Web PubSub resource and the server app running locally":::
243
+
:::image type="content" source="media/howto-integrate-app-gateway/local-browser-client-indirect.jpg" alt-text="Screenshot of a browser client indirectly connected with Web PubSub resource and the server app running locally.":::
244
244
245
245
### Recap of step 1
246
246
We reached the end of step 1. If you have been following step 1, you should see that your Web PubSub resource is accessible directly by your web clients **and** indirectly through Application Gateway. You also saw Application Gateway's native support for WebSocket in action. Enabling it doesn't require any configuration changes. We only need to make sure that a web client points to an Application Gateway endpoint. The rest of the access URL generated from Web PubSub service SDK should remain unchanged.
@@ -284,6 +284,10 @@ Create a Private Endpoint in the same region as your Web PubSub resource.
284
284
Select the separate subnet we just created.
285
285
:::image type="content" source="media/howto-integrate-app-gateway/web-pubsub-create-private-endpoint-step-3.jpg" alt-text="Place Web PubSub's Private Endpoint in the newly created subnet.":::
### Refresh the backend pool of your Application Gateway resource
288
292
Your Application Gateway resource doesn't know that you created a Private Endpoint for your Web PubSub resource. Locate your Application Gateway resource and refresh the backend pools.
@@ -341,7 +345,7 @@ There are two environment variables we need to set and make available to `publis
341
345
342
346
- Find your connection string to Web PubSub service on Azure portal, and set the `WebPubSubConnectionString` environment variable.
343
347
- Find the Frontend public IP of your Application Gateway resource, and set the `appGatewayEndpoint`environment variable.
344
-
:::image type="content" source="media/howto-integrate-app-gateway/web-app-set-environment-variables.jpg" alt-text="Screenshot of setting two environment variables of a Web App":::
348
+
:::image type="content" source="media/howto-integrate-app-gateway/web-app-set-environment-variables.jpg" alt-text="Screenshot of setting two environment variables of a Web App.":::
345
349
346
350
#### Enable Virtual Network integration on your Web App
347
351
App Service requires a dedicated subnet in your Virtual Network. Go to your Virtual Network resource and create a new subnet like what you did for your Web PubSub resource.
0 commit comments