refactor for metallb

This commit is contained in:
2024-08-26 12:41:26 +10:00
parent 4752c35680
commit f41889854d
8 changed files with 15 additions and 32 deletions

View File

@@ -2,13 +2,7 @@ apiVersion: metallb.io/v1beta1
kind: L2Advertisement kind: L2Advertisement
metadata: metadata:
name: l2-advertisement name: l2-advertisement
namespace: metallb namespace: metallb-system
spec: spec:
ipAddressPools: ipAddressPools:
- k3s-cluster-ips - k3s-cluster-ips
nodeSelectors:
- matchExpressions:
- key: kubernetes.io/os
operator: In
values:
- linux

View File

@@ -2,11 +2,8 @@ apiVersion: metallb.io/v1beta1
kind: IPAddressPool kind: IPAddressPool
metadata: metadata:
name: k3s-cluster-ips name: k3s-cluster-ips
namespace: metallb namespace: metallb-system
spec: spec:
addresses: addresses:
- 192.168.10.100/32 - 192.168.10.100-192.168.10.103
- 192.168.10.101/32 - 192.168.10.120
- 192.168.10.102/32
- 192.168.10.103/32
- 192.168.10.120/32

View File

@@ -1,8 +1,8 @@
{ {
"appName": "metallb-conf", "appName": "metallb-conf",
"userGivenName": "metallb-conf", "userGivenName": "metallb-conf",
"namespace": "metallb", "namespace": "metallb-system",
"destNamespace": "metallb", "destNamespace": "metallb-system",
"destServer": "https://kubernetes.default.svc", "destServer": "https://kubernetes.default.svc",
"srcPath": "infrastructures/metallb-conf/env/k3s-cluster", "srcPath": "infrastructures/metallb-conf/env/k3s-cluster",
"srcRepoURL": "https://github.com/3dwardch3ng/home-cluster-ops.git", "srcRepoURL": "https://github.com/3dwardch3ng/home-cluster-ops.git",

View File

@@ -1,5 +1,5 @@
apiVersion: kustomize.config.k8s.io/v1beta1 apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
resources: resources:
- ./advertisement.yaml - ./cluster-ip.yaml
- ./cluster-ip.yaml - ./advertisement.yaml

View File

@@ -1,8 +1,8 @@
{ {
"appName": "metallb", "appName": "metallb",
"userGivenName": "metallb", "userGivenName": "metallb",
"namespace": "metallb", "namespace": "metallb-system",
"destNamespace": "metallb", "destNamespace": "metallb-system",
"destServer": "https://kubernetes.default.svc", "destServer": "https://kubernetes.default.svc",
"srcPath": "infrastructures/metallb/env/k3s-cluster", "srcPath": "infrastructures/metallb/env/k3s-cluster",
"srcRepoURL": "https://github.com/3dwardch3ng/home-cluster-ops.git", "srcRepoURL": "https://github.com/3dwardch3ng/home-cluster-ops.git",

View File

@@ -2,7 +2,6 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization kind: Kustomization
helmCharts: helmCharts:
- name: metallb - name: metallb
repo: oci://registry-1.docker.io/bitnamicharts repo: https://metallb.github.io/metallb
version: 6.3.10 version: 0.14.18
releaseName: metallb releaseName: metallb
valuesFile: values.yaml

View File

@@ -1,7 +0,0 @@
namespaceOverride: "metallb"
controller:
podSecurityContext:
fsGroup: 1000
containerSecurityContext:
runAsUser: 1000
runAsGroup: 1000

View File

@@ -4,6 +4,6 @@ metadata:
annotations: annotations:
argocd.argoproj.io/sync-options: Prune=false argocd.argoproj.io/sync-options: Prune=false
creationTimestamp: null creationTimestamp: null
name: metallb name: metallb-system
spec: {} spec: {}
status: {} status: {}