...
Code Block | ||||
---|---|---|---|---|
| ||||
apiVersion: v1 kind: ConfigMap metadata: namespace: metallb-system name: config data: config: | layer2: addresses: - 192.168.114.101-192.168.114.101 # machine where K3S is installed - 192.168.114.200-192.168.114.210 |
Make sure the IP range specified is within your local network range and does not conflict with existing devices.
...
Code Block | ||||
---|---|---|---|---|
| ||||
apiVersion: metallb.io/v1beta1 kind: L2Advertisement metadata: name: example namespace: metallb-system spec: ipAddressPools: - first-pool |
...
kubectl apply -f
metallb-advertise.yaml
d. Check ingress (traefik) gets loadbalancer address of the machine
kubectl get services -A
Install ArgoCD
Before installing ArgoCD, create a namespace where ArgoCD resources will live:
...
Wait for everything ready.
Expose the ArgoCD Server
By default, the ArgoCD API server is only accessible inside the cluster. To access it externally, you can expose it using either a NodePort
or LoadBalancer
service. For a minimal installation like K3s, NodePort
is typically used.
a. Expose ArgoCD with a NodePort:
Run this command to patch the argocd-server
service to be of type NodePort
:
kubectl patch svc argocd-server -n argocd -p '{"spec": {"type": "NodePort"}}'
To retrieve the NodePort, run the following command:
kubectl get svc -n argocd argocd-server
Look for the NodePort
value under the PORT(S)
column.
...
You can now access the ArgoCD web UI at
http://<Node_IP>:<NodePort>
.
https://<Node_IP>:<NodePort>
Node_IP
= address/dns of the machine where is installed k3s