Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

MetalLB: update to v0.13.9 #898

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

claviola
Copy link

@claviola claviola commented May 3, 2023

Description

  • now uses a single manifest
  • supports aarch64 (ARM), so remove the Intel-only restriction

Motivation and Context

Updating the MetalLB chart to v0.13.9 should fix #896, ie. allow it to be installed on ARM.

  • [N] I have raised an issue to propose this change, which has been given a label of design/approved by a maintainer (required)

I have indeed raised an issue to propose this change, but I do not yet understand how the labelling works. However, since @alexellis asked me if I'd fix it myself I've gone ahead and done it. I'm sure we can work out the details.

How Has This Been Tested?

Followed all the steps in CONTRIBUTING - including building and attempting to reinstall:

[claviola@fedora arkade]$ kubectl delete -f https://raw.githubusercontent.com/metallb/metallb/v0.13.9/config/manifests/metallb-native.yaml
namespace "metallb-system" deleted
customresourcedefinition.apiextensions.k8s.io "addresspools.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "bfdprofiles.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "bgpadvertisements.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "bgppeers.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "communities.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "ipaddresspools.metallb.io" deleted
customresourcedefinition.apiextensions.k8s.io "l2advertisements.metallb.io" deleted
serviceaccount "controller" deleted
serviceaccount "speaker" deleted
role.rbac.authorization.k8s.io "controller" deleted
role.rbac.authorization.k8s.io "pod-lister" deleted
clusterrole.rbac.authorization.k8s.io "metallb-system:controller" deleted
clusterrole.rbac.authorization.k8s.io "metallb-system:speaker" deleted
rolebinding.rbac.authorization.k8s.io "controller" deleted
rolebinding.rbac.authorization.k8s.io "pod-lister" deleted
clusterrolebinding.rbac.authorization.k8s.io "metallb-system:controller" deleted
clusterrolebinding.rbac.authorization.k8s.io "metallb-system:speaker" deleted
secret "webhook-server-cert" deleted
service "webhook-service" deleted
deployment.apps "controller" deleted
daemonset.apps "speaker" deleted
validatingwebhookconfiguration.admissionregistration.k8s.io "metallb-webhook-configuration" deleted
[claviola@fedora arkade]$ ./arkade version
            _             _      
  __ _ _ __| | ____ _  __| | ___ 
 / _` | '__| |/ / _` |/ _` |/ _ \
| (_| | |  |   < (_| | (_| |  __/
 \__,_|_|  |_|\_\__,_|\__,_|\___|

Open Source Marketplace For Developer Tools

Version: dev
Git Commit: 

 馃惓 arkade needs your support: https://github.com/sponsors/alexellis
[claviola@fedora arkade]$ kubectl get nodes -o wide
NAME      STATUS   ROLES                       AGE     VERSION        INTERNAL-IP     EXTERNAL-IP   OS-IMAGE                         KERNEL-VERSION   CONTAINER-RUNTIME
rpi-001   Ready    control-plane,etcd,master   2d21h   v1.26.4+k3s1   192.168.2.151   <none>        Debian GNU/Linux 11 (bullseye)   6.1.21-v8+       containerd://1.6.19-k3s1
rpi-002   Ready    control-plane,etcd,master   2d21h   v1.26.4+k3s1   192.168.2.156   <none>        Debian GNU/Linux 11 (bullseye)   6.1.21-v8+       containerd://1.6.19-k3s1
rpi-003   Ready    control-plane,etcd,master   2d21h   v1.26.4+k3s1   192.168.2.155   <none>        Debian GNU/Linux 11 (bullseye)   6.1.21-v8+       containerd://1.6.19-k3s1
[claviola@fedora arkade]$ ./arkade install metallb-arp
Using Kubeconfig: /media/psf/shared/rpi-config
namespace/metallb-system created
customresourcedefinition.apiextensions.k8s.io/addresspools.metallb.io created
customresourcedefinition.apiextensions.k8s.io/bfdprofiles.metallb.io created
customresourcedefinition.apiextensions.k8s.io/bgpadvertisements.metallb.io created
customresourcedefinition.apiextensions.k8s.io/bgppeers.metallb.io created
customresourcedefinition.apiextensions.k8s.io/communities.metallb.io created
customresourcedefinition.apiextensions.k8s.io/ipaddresspools.metallb.io created
customresourcedefinition.apiextensions.k8s.io/l2advertisements.metallb.io created
serviceaccount/controller created
serviceaccount/speaker created
role.rbac.authorization.k8s.io/controller created
role.rbac.authorization.k8s.io/pod-lister created
clusterrole.rbac.authorization.k8s.io/metallb-system:controller created
clusterrole.rbac.authorization.k8s.io/metallb-system:speaker created
rolebinding.rbac.authorization.k8s.io/controller created
rolebinding.rbac.authorization.k8s.io/pod-lister created
clusterrolebinding.rbac.authorization.k8s.io/metallb-system:controller created
clusterrolebinding.rbac.authorization.k8s.io/metallb-system:speaker created
secret/webhook-server-cert created
service/webhook-service created
deployment.apps/controller created
daemonset.apps/speaker created
validatingwebhookconfiguration.admissionregistration.k8s.io/metallb-webhook-configuration created
configmap/config created
=======================================================================
= MetalLB has been installed.                                         =
=======================================================================


# Get the memberlist secretkey:
export SECRET_KEY=$(kubectl get secret -n metallb-system memberlist \
	-o jsonpath="{.data.secretkey}" | base64 --decode)

echo "Secret Key: $SECRET_KEY"

# Review the generated configuration:

kubectl get configmap -n metallb-system config --template={{.data.config}}

# Find out more at: https://metallb.universe.tf/


馃惓 arkade needs your support: https://github.com/sponsors/alexellis
[claviola@fedora arkade]$ export SECRET_KEY=$(kubectl get secret -n metallb-system memberlist \
        -o jsonpath="{.data.secretkey}" | base64 --decode)

echo "Secret Key: $SECRET_KEY"
Secret Key: ...
[claviola@fedora arkade]$ kubectl get configmap -n metallb-system config --template={{.data.config}}
address-pools:
- name: default
  protocol: layer2
  addresses:
  - 192.168.0.0/24

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Documentation

  • [NA] I have updated the list of tools in README.md if (required) with ./arkade get -o markdown
  • [NA] I have updated the list of apps in README.md if (required) with ./arkade install --help

Checklist:

  • My code follows the code style of this project.
  • [NA] My change requires a change to the documentation.
  • [NA] I have updated the documentation accordingly.
  • I've read the CONTRIBUTION guide
  • I have signed-off my commits with git commit -s

@derek
Copy link

derek bot commented May 3, 2023

Thank you for your contribution. unfortunately, one or more of your commits are missing the required "Signed-off-by:" statement. Signing off is part of the Developer Certificate of Origin (DCO) which is used by this project.

Read the DCO and project contributing guide carefully, and amend your commits using the git CLI. Note that this does not require any cryptography, keys or special steps to be taken.

馃挕 Shall we fix this?

This will only take a few moments.

First, clone your fork and checkout this branch using the git CLI.

Next, set up your real name and email address:

git config --global user.name "Your Full Name"
git config --global user.email "you@domain.com"

Finally, run one of these commands to add the "Signed-off-by" line to your commits.

If you only have one commit so far then run: git commit --amend --signoff and then git push --force.
If you have multiple commits, watch this video.

Check that the message has been added properly by running "git log".

- now uses a single manifest
- supports aarch64 (ARM), so remove the Intel-only restriction

Signed-off-by: Carlos Laviola <carlos.laviola@gmail.com>
@alexellis
Copy link
Owner

Hey thanks for working on this PR for Arm support for MetalLB.

I always feel uncomfortable merging things when I see the words "it should work" and then under testing, I don't see any evidence that the thing being fixed has been tested.

Under How Has This Been Tested? could you edit and show the console output from arkade install, along with the node architecture? kubectl get node -o wide. And then finally, show that MetalLB worked as it was meant to?

Feel free to look at merged PRs for where the other contributors have done this.

Cheers,

Alex

@claviola
Copy link
Author

claviola commented May 3, 2023

All done!

@claviola
Copy link
Author

claviola commented May 3, 2023

Actually there's a small change in configuration required for this to be done seamlessly. As per the docs, something like this has to be created at the same time as the address pool:

apiVersion: metallb.io/v1beta1
kind: L2Advertisement
metadata:
聽 name: example
聽 namespace: metallb-system

do you have any suggestions for the name of this L2Advertisement instance?

@claviola
Copy link
Author

claviola commented May 3, 2023

Unfortunately I'm having trouble changing from the ConfigMap to CRDs.

Is it alright to just output text telling the user what to do to configure the app further, like in other apps such as https://github.com/claviola/arkade/blob/master/cmd/apps/kubernetes_dashboard_app.go#L83?

@alexellis
Copy link
Owner

alexellis commented May 31, 2023

Unfortunately I'm having trouble changing from the ConfigMap to CRDs.

Can you elaborate please? I'll try to help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

metallb-arp should install on arm64
2 participants