Configure Private Endpoints for Azure Event Grid
Configuring private endpoints for Azure Event Grid allows secure private access to Event Grid resources over your Azure Virtual Network. Azure Private Endpoints ensures the traffic between Apporetum and Event Grid remains private and not exposed to the public internet. This short guide describes how to set up Private Endpoints for Event Grid.
Create a New Subnet for EventGrid
This step can be skipped if you plan to deploy eventgrid into an existing Apporetum Subnet
- Navigate to the Virtual Network where Apporetum is deployed.
- Navigate to the
settingsblade and selectsubnets. - Click
+ Subnetto create a new subnet. - Give the subnet a name and select
Save
Attaching Private Endpoint to Existing Event Grid
- Deploy Event Grid
Information on deploying Event Grid for Apporetum can be found here.
- Navigate to the Deployed Event Grid and access the
Networkingblade. - Set "Allow Access From" to
Private endpoints only. - Select the
Private endpoint connectionstab. - Click
+ Private endpointto create a new Private Endpoint. - Give the private endpoint a unique identifying name and select
Next. - Continue to the Virtual Network tab.
- Under Virtual Network - Select the Virtual Network where Apporetum is deployed too.
- Under Subnet - Select the subnet that was deployed for Event Grid (See step above) and select
Next. - Select Review and Create the Private endpoint.
Configure Apporetum to use the Private Endpoint
- Navigate to the Apporetum Managed Resource Group.
- Select the API App Service.
- Under the
Settingsblade selectNetworking. - Under
Inbound traffic configurationselect the Public network access option. - Under
Public network accessselectEnabled from select virtual networks and IP addresses. - Under the
Unmatched rule actionselectallow. - Click
+ Addto add a new network rule to allow the traffic from the virutal network and subnet to reach the API App service. - Give the new rule an appropriate name and set the following configurations:
SubscriptionSelect the subscription where Apporetum is deployed.Virutal NetworkSelect the virtual network where apporetum is deployed.SubnetSelect the subnet that was created for the EventGrid. If EventGrid was deployed to another subnet, ensure that subnet is chosen.
- Click Save.
Configure Event Grid - Create webhook
-
Navigate to deployed Event Grid.
-
Select
Domain-Scope Event Subscriptionsin theEntitiesblade. -
Select
+ New Event Subscription -
Give the Event Subscription a name and select
CloudEventSchemaV1_0as the Event Schema. -
Under Endpoint Type select
Web hook -
Navigate to Apporetum copy the web hook. This can be done by navigating to
Settings->Event Viewer. -
Copy the Web hook URL.
-
Navigate back to Azure Event Grid and paste the URL under
Web hook. -
Click
Create.
-
Apporetum has now been configured to use Private Endpoints for Azure Event Grid. Apporetum events should now populate when you navigate to
Settings->Event Viewer.