Giter Site home page Giter Site logo

richard-9000 / metallb-neighbour-helper Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kradalby/metallb-neighbour-helper

0.0 0.0 0.0 62 KB

MetalLB helper to automatically add nodes to BGP router (OPNSense)

Dockerfile 1.29% Go 92.12% Makefile 1.76% Mustache 4.83%

metallb-neighbour-helper's Introduction

metallb-neighbour-helper

This project aims to "help" a Kubernetes cluster which uses MetalLB to register its nodes to the BGP router MetalLB talks to.

The development is best effort and mostly for fun and to solve my own problems.

Currently, this projects implements OPNsense with the FRR package. I hope to add more providers in the future, and I have VMware vCloud in mind.

The implementation is pretty naive, it takes a look at the MetalLB configmap and uses the AS numbers defined there.

When the service is added to the Kubernetes cluster it will check if all the Nodes are registered with the BGP host and if not, add them. There is currently not any smart logic to select which nodes should be registered.

After the initial registration, a watcher of the Node object in the cluster is started and if nodes are added or deleted, the BGP host will be updated accordingly.

There is currently not any smart logic if any of the configmaps (MetalLB or the helper) is updated and the pod should be restarted.

Contributions and suggestions are welcome ๐Ÿ˜€

Installation

First install MetalLB according to their installation documentation and configuration documentation.

If you install by applying the yaml file, the configuration in the example/ directory.

The example/ configuration should be fine in most cases, but a few things might need to be configured:

In the metallb-helper.yaml the following parts might need configuration: (See comments in the file)

  • namespace: for the Deployment must be the same as MetalLB
  • serviceAccountName: must be the same as the metallb-speaker (probably speaker or metallb-speaker)
  • args: must be the name of the ConfigMap for MetalLB and the MetalLB Helper

In the metallb-helper-configmap.yaml the following parts might need configuration: (See comments in the file)

  • namespace: for the ConfigMap must be the same as MetalLB
  • peer-address: must be the same IP/Address as the peer-address in the associated peer in MetalLB

Helm chart

I have added a Helm chart to the repo, should allow easy installation, remember to check the variables mentioned over and read the values that can be configured in values.yaml

metallb-neighbour-helper's People

Contributors

kradalby avatar renovate-bot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.