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/aks/limit-egress-traffic.md
+13-13Lines changed: 13 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,18 +1,18 @@
1
1
---
2
-
title: Control egress traffic using Azure Firewall in Azure Kubernetes Service (AKS)
3
-
description: Learn how to control egress traffic using Azure Firewall in Azure Kubernetes Service (AKS)
2
+
title: Limit Network Traffic with Azure Firewall in Azure Kubernetes Service (AKS)
3
+
description: Learn how to control egress traffic with Azure Firewall to set restrictions for outbound network connections in AKS clusters.
4
4
ms.subservice: aks-networking
5
5
ms.custom: devx-track-azurecli, devx-track-linux
6
6
ms.topic: how-to
7
7
ms.author: allensu
8
-
ms.date: 03/10/2023
8
+
ms.date: 12/05/2023
9
9
author: asudbring
10
10
#Customer intent: As a cluster operator, I want to restrict egress traffic for nodes to only access defined ports and addresses and improve cluster security.
11
11
---
12
12
13
-
# Control egress traffic using Azure Firewall in Azure Kubernetes Service (AKS)
13
+
# Limit network traffic with Azure Firewall in Azure Kubernetes Service (AKS)
14
14
15
-
This article provides a walkthrough of how to use the [Outbound network and FQDN rules for AKS clusters][outbound-fqdn-rules] to control egress traffic using Azure Firewall in AKS. To simplify this configuration, Azure Firewall provides an Azure Kubernetes Service (`AzureKubernetesService`) FQDNthat restricts outbound traffic from the AKS cluster. This article also provides an example of how to configure public inbound traffic via the firewall.
15
+
Learn how to use the [Outbound network and FQDN rules for AKS clusters][outbound-fqdn-rules] to control egress traffic using the Azure Firewall in AKS. To simplify this configuration, Azure Firewall provides an Azure Kubernetes Service (`AzureKubernetesService`) Fully Qualified Domain Name (FQDN) tag that restricts outbound traffic from the AKS cluster. This article shows how you can configure your AKS Cluster traffic rules through Azure firewall.
16
16
17
17
> [!NOTE]
18
18
>
@@ -36,7 +36,7 @@ The following information provides an example architecture of the deployment:
36
36
***Internal traffic**
37
37
* You can use an [internal load balancer](internal-lb.md) for internal traffic, which you could isolate on its own subnet, instead of or alongside a [public load balancer](load-balancer-standard.md)
38
38
39
-
## Set configuration using environment variables
39
+
## Configure environment variables
40
40
41
41
Define a set of environment variables to be used in resource creations.
42
42
@@ -90,7 +90,7 @@ Provision a virtual network with two separate subnets: one for the cluster and o
90
90
--address-prefix 10.42.2.0/24
91
91
```
92
92
93
-
## Create and set up an Azure Firewall with a UDR
93
+
## Create and set up an Azure Firewall
94
94
95
95
You need to configure Azure Firewall inbound and outbound rules. The main purpose of the firewall is to enable organizations to configure granular ingress and egress traffic rules into and out of the AKS cluster.
96
96
@@ -108,7 +108,7 @@ You need to configure Azure Firewall inbound and outbound rules. The main purpos
2. Register the [Azure Firewall preview CLI extension](https://github.com/Azure/azure-cli-extensions/tree/main/src/azure-firewall) to create an Azure Firewall using the [`az extension add`][az-extension-add] command.
111
+
2. Register the [Azure Firewall CLI extension](https://github.com/Azure/azure-cli-extensions/tree/main/src/azure-firewall) to create an Azure Firewall using the [`az extension add`][az-extension-add] command.
112
112
113
113
```azurecli-interactive
114
114
az extension add --name azure-firewall
@@ -143,12 +143,12 @@ You need to configure Azure Firewall inbound and outbound rules. The main purpos
143
143
>
144
144
> If you use secure access to the AKS API server with [authorized IP address ranges](./api-server-authorized-ip-ranges.md), you need to add the firewall public IP into the authorized IP range.
145
145
146
-
### Create a UDR with a hop to Azure Firewall
146
+
### Create a route with a hop to Azure Firewall
147
147
148
148
Azure automatically routes traffic between Azure subnets, virtual networks, and on-premises networks. If you want to change any of Azure's default routing, you can create a route table.
149
149
150
150
> [!IMPORTANT]
151
-
> Outbound type of UDR requires a route for 0.0.0.0/0 and a next hop destination of NVA in the route table.
151
+
> Outbound type of UDR (`userDefinedRouting`) requires a route for 0.0.0.0/0 and a next hop destination of NVA in the route table.
152
152
> The route table already has a default 0.0.0.0/0 to the Internet. Without a public IP address for Azure to use for Source Network Address Translation (SNAT), simply adding this route won't provide you outbound Internet connectivity. AKS validates that you don't create a 0.0.0.0/0 route pointing to the Internet but instead to a gateway, NVA, etc.
153
153
> When using an outbound type of UDR, a load balancer public IP address for **inbound requests** isn't created unless you configure a service of type *loadbalancer*. AKS never creates a public IP address for **outbound requests** if you set an outbound type of UDR.
154
154
> For more information, see [Outbound rules for Azure Load Balancer](../load-balancer/outbound-rules.md#scenario6out).
@@ -212,7 +212,7 @@ To associate the cluster with the firewall, the dedicated subnet for the cluster
## Deploy an AKS cluster with a UDR outbound type to the existing network
215
+
## Deploy an AKS cluster that follows your outbound rules
216
216
217
217
Now, you can deploy an AKS cluster into the existing virtual network. You will use the [`userDefinedRouting` outbound type](egress-outboundtype.md), which ensures that any outbound traffic is forced through the firewall and no other egress paths will exist. The [`loadBalancer` outbound type](egress-outboundtype.md#outbound-type-of-loadbalancer) can also be used.
218
218
@@ -346,7 +346,7 @@ If you used authorized IP ranges for your cluster in the previous step, you need
346
346
az aks get-credentials -g $RG -n $AKSNAME
347
347
```
348
348
349
-
## Deploy a public service
349
+
## Deploy a public service on AKS
350
350
351
351
You can now start exposing services and deploying applications to this cluster. In this example, we'll expose a public service, but you also might want to expose an internal service using an [internal load balancer](internal-lb.md).
352
352
@@ -360,7 +360,7 @@ You can now start exposing services and deploying applications to this cluster.
0 commit comments