techno-tim / k3s-ansible

The easiest way to bootstrap a self-hosted High Availability Kubernetes cluster. A fully automated HA k3s etcd install with kube-vip, MetalLB, and more. Build. Destroy. Repeat.
https://technotim.live/posts/k3s-etcd-ansible/
Apache License 2.0
2.41k stars 1.05k forks source link

Metallb BGP support #212

Closed mikethms closed 1 year ago

mikethms commented 1 year ago

Proposed Changes

Checklist

timothystewart6 commented 1 year ago

How can we test this with molecule? If we can't test with molecule can we check for resources in process like we do for other metallb resources? https://github.com/techno-tim/k3s-ansible/blob/master/roles/k3s/post/tasks/metallb.yml

timothystewart6 commented 1 year ago

@Undefining would love to merge this but wanted to check on https://github.com/techno-tim/k3s-ansible/pull/212#issuecomment-1407941614

mikethms commented 1 year ago

I hopefully have time at the end of the week to see if I can write some molecule tests for this. Otherwise checking for created resources would also work.

timothystewart6 commented 1 year ago

Thank you @Undefining ! I really appreciate it!

mikethms commented 1 year ago

Had some issues with my local molecule environment, unfortunately don't have the time to fully look into that. I compared a layer 2 deployment with a bgp deployment. Luckily most of the checks in the metallb post tasks align with both types of deployment. I only needed to add a check for creation of BGPPeer and BGPAdvertisement.

mikethms commented 1 year ago

Updated the pattern, the frr manifest gets downloaded as well.

timothystewart6 commented 1 year ago

Thank you so much!

timothystewart6 commented 1 year ago

Maybe I am missing something or something was overlooked when you created another PR but we added metal_lb_frr_tag_version but it looks like it isn't being referenced anywhere. This tag does exist in the manifests but we aren't overriding it with regex. Not sure if this is really needed or not. https://raw.githubusercontent.com/metallb/metallb/v0.13.7/config/manifests/metallb-frr.yaml