mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2025-12-13 21:34:40 +03:00
Network plugin custom (#9819)
* network_plugin/custom_cni: add CNI to apply provided manifests Add a new simple custom_cni to install provided Kubernetes manifests. This could be useful to use manifests directly provided by a CNI when there are not support by Kubespray (i.e.: helm chart or any other manifests generation method). Co-authored-by: James Landrein <james.landrein@proton.ch> Signed-off-by: Arthur Outhenin-Chalandre <arthur.outhenin-chalandre@proton.ch> * network_plugin/custom_cni: add test with cilium Co-authored-by: James Landrein <james.landrein@proton.ch> Signed-off-by: Arthur Outhenin-Chalandre <arthur.outhenin-chalandre@proton.ch> --------- Signed-off-by: Arthur Outhenin-Chalandre <arthur.outhenin-chalandre@proton.ch> Co-authored-by: James Landrein <james.landrein@proton.ch>
This commit is contained in:
committed by
GitHub
parent
677b7ecd89
commit
6769bb32b1
11
tests/files/custom_cni/README.md
Normal file
11
tests/files/custom_cni/README.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Custom CNI manifest generation
|
||||
|
||||
As an example we are using Cilium for testing the network_plugins/custom_cni.
|
||||
|
||||
To update the generated manifests to the latest version do the following:
|
||||
|
||||
```sh
|
||||
helm repo add cilium https://helm.cilium.io/
|
||||
helm repo update
|
||||
helm template cilium/cilium -n kube-system -f values.yaml > cilium.yaml
|
||||
```
|
||||
1056
tests/files/custom_cni/cilium.yaml
Normal file
1056
tests/files/custom_cni/cilium.yaml
Normal file
File diff suppressed because it is too large
Load Diff
11
tests/files/custom_cni/values.yaml
Normal file
11
tests/files/custom_cni/values.yaml
Normal file
@@ -0,0 +1,11 @@
|
||||
---
|
||||
|
||||
# We disable hubble so that helm doesn't try to generate any certificate.
|
||||
# This is not needed to test network_plugin/custom_cni anyway.
|
||||
hubble:
|
||||
enabled: false
|
||||
|
||||
ipam:
|
||||
operator:
|
||||
# Set the appropriate pods subnet
|
||||
clusterPoolIPv4PodCIDR: "{{ kube_pods_subnet }}"
|
||||
9
tests/files/packet_debian11-custom-cni.yml
Normal file
9
tests/files/packet_debian11-custom-cni.yml
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
# Instance settings
|
||||
cloud_image: debian-11
|
||||
mode: default
|
||||
|
||||
# Kubespray settings
|
||||
kube_network_plugin: custom_cni
|
||||
custom_cni_manifests:
|
||||
- tests/files/custom_cni/cilium.yaml
|
||||
Reference in New Issue
Block a user