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: Standards/scs-XXXX-v1-kaas-networking.md
+23-25Lines changed: 23 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,46 +35,44 @@ We should also be explicit about the required versions of the APIs.
35
35
36
36
#### NetworkPolicy API
37
37
38
-
Kubernetes network policies allow the restrict network traffic within a cluster based on labels and namespaces.
39
-
They must be implemented by the CNI plugin of the cluster and are technically optional, though they are few CNI plugins that do not support them.
38
+
Kubernetes network policies can restrict network traffic within a cluster based on labels and namespaces.
39
+
They must be implemented by the CNI plugin of the cluster and are technically optional, though the majority of CNI plugins support them.
40
40
41
-
Network policies are an important security feature that allows a separation of components and namespaces on a network level.
41
+
Network policies are an important and widely used security feature, and the existing wide support among CNI plugins makes them a good target for SCS standardization.
42
42
43
-
- already defacto standard, will be expected by many users, so we should make it explicit
44
-
45
-
#### AdminNetworkPolicy API
43
+
#### Default Network Policies in Namespaces
46
44
47
45
Basic network policies are always bound to a namespace, and only affect connections to and from pods within this namespace.
48
-
Restricting certain traffic within the whole cluster requires a policy to be replicated across all namespaces.
49
-
There are operators, such as Kyverno, that can handle this replication automatically and will also create policies for newly created namespaces.
46
+
Without them, pods are reachable by any other pod in the cluster and also can connect to any external address.
47
+
48
+
Automatically creating default network policies in new namespaces can be desirable but requires an operator such as Kyverno.
49
+
A CSP could provide such an operator and offer a number of default policies, like blocking connections to other namespaces by default, or blocking access to the OpenStack metadata service.
50
50
51
-
Some CNI plugins have implemented their own extensions for cluster-wide networking rules, such as Calico's `GlobalNetworkPolicy` and Cilium's `CiliumClusterwideNetworkPolicy`.
52
-
The Kubernetes Network Policy Special Interest Group is currently working on an official API extension to cover this functionality.
51
+
Any user with permissions to manage their own network policies in a namespace will of course be able to remove or modify any default network policies in that namespace.
52
+
CSP-provided network policies should therefore only be viewed as a safety default, and should only be deployed if they are actually beneficial to users.
53
+
54
+
#### AdminNetworkPolicy API
53
55
54
-
- AdminNetworkPolicy replaces CNI-specific APIs
55
-
- we can not mandate this until it is stable
56
-
- could be required in a future version of this standard
57
-
- we can recomend CNIs that are already working on support
56
+
An alternative to automatically created default network policies are API extensions that allow cluster-wide networking rules.
57
+
Some CNI plugins have implemented such extensions, e.g. Calico's `GlobalNetworkPolicy` and Cilium's `CiliumClusterwideNetworkPolicy`.
58
58
59
-
#### Default Network Policies in Cluster
59
+
The Kubernetes Network Policy Special Interest Group is currently working on an official API extension to cover this functionality [^adminnetpol].
60
+
This API extension introduces the new `AdminNetworkPolicy` and `BaselineAdminNetworkPolicy` resources, which represent cluster-wide network policies with respectively higher or lower precedence than namespaced network policies.
60
61
61
-
- providing defaults is possible even without AdminNetworkPolicy by either operator or CNI-specifics
62
-
- what are useful defaults?
63
-
- is there actually a demand for CSP-set defaults?
62
+
This API is also a good candidate for standardization because it consolidates a number of vendor-specific workarounds to limitations of the NetworkPolicy API.
63
+
It has not been stabilized yet, so currently we can at most recommend CNI plugins where there is ongoing work to support this feature.
64
64
65
65
#### Ingress API
66
66
67
-
The Ingress API allows the external exposure of HTTP(S)-based services running in the cluster.
67
+
The Ingress API allows the external exposure of HTTP/HTTPS-based services running in the cluster.
68
68
Unlike the L3/L4-based LoadBalancer Service type, Ingress provides L7 load balancing, HTTP routing, and TLS termination for services.
69
69
This functionality can be provided within the cluster by a pod-based ingress controller such as `ingress-nginx`, that is itself exposed as a Service.
70
70
71
-
However, there are also Ingress controllers that integrate with the underlying infrastructure and may reduce some overhead.
72
-
Examples for this are the Cilium CNI plugin, which comes with bhuilt-in Ingress support, and the Octavia ingress controller, which might be a good choice if OpenStack Octavia is already used to provide Service load balancing.
71
+
However, there are also Ingress controllers that integrate with underlying infrastructure and may help to reduce overhead.
72
+
Examples for this are the Cilium CNI plugin, which comes with built-in Ingress support, and the Octavia ingress controller, which may be a good choice if OpenStack Octavia is already used to provide L3/L4 load balancing.
73
73
74
-
- Ingress controllers seem to be regularly requested by managed k8s users
75
-
- managed ingress controller may have better integration in infrastructure
76
-
- some users may prefer to deploy their own ingress controllers, e.g. if they have additional requirements such as the gateway API
77
-
- CSPs could offer option to set up ingress controller
74
+
The choice for such an externally integrated Ingress controller can of course be best made by the CSP that manages the underlying infrastructure.
75
+
While some users may still want to deploy their own ingress controller, many will also use a CSP-provided one if available.
0 commit comments