Title here
Summary here
You’ll need IPs to hand out
Verify requirements
kubectl edit configmap -n kube-system kube-proxy
# add blah blah, it's in the documentationkubectl create namespace metallbor use a manifest file:
cat << EOF > metallb_ns.yaml
kind: Namespace
apiVersion: v1
metadata:
name: metallb
labels:
pod-security.kubernetes.io/enforce: privileged
pod-security.kubernetes.io/audit: privileged
pod-security.kubernetes.io/warn: privileged
EOFkubectl apply -f metallb_ns.yamlIf you didn’t add labels to the metallb namespace at creation:
Test:
kubectl label --dry-run=server --overwrite ns metallb \
pod-security.kubernetes.io/enforce=privileged \
pod-security.kubernetes.io/audit=privileged \
pod-security.kubernetes.io/warn=privilegedRun for real:
kubectl label --overwrite ns metallb \
pod-security.kubernetes.io/enforce=privileged \
pod-security.kubernetes.io/audit=privileged \
pod-security.kubernetes.io/warn=privilegedSee also: https://kubernetes.io/docs/tasks/configure-pod-container/enforce-standards-namespace-labels
helm repo add metallb https://metallb.github.io/metallb
helm -n metallb install metallb metallb/metallbcat << EOF > metallb_config.yml
apiVersion: metallb.io/v1beta1
kind: IPAddressPool
metadata:
name: example
namespace: metallb
spec:
addresses:
- 192.168.13.85-192.168.13.90
EOFAppend to the metallb_config.yml file
apiVersion: metallb.io/v1beta1
kind: L2Advertisement
metadata:
name: example
namespace: metallbFull file:
apiVersion: metallb.io/v1beta1
kind: IPAddressPool
metadata:
name: example
namespace: metallb
spec:
addresses:
- 192.168.13.85-192.168.13.90
---
apiVersion: metallb.io/v1beta1
kind: L2Advertisement
metadata:
name: example
namespace: metallbcat << EOF > metallb.yml
apiVersion: metallb.io/v1beta1
kind: IPAddressPool
metadata:
name: example
namespace: metallb
spec:
addresses:
- 192.168.13.85-192.168.13.90
---
apiVersion: metallb.io/v1beta1
kind: L2Advertisement
metadata:
name: example
namespace: metallb
EOF