Git Product home page Git Product logo

mycni's Introduction

MyCNI

A simple CNI plugin for kubernetes, similar with Flannel host-gw.

Components

mycni: CNI plugin for containers, create Linux Bridge, veth pair and assign IP for Pod. mycnid: daemon service on each host, watch Nodes and set routes, iptables for each host.

Network architecture: mycni-network-arch

Quick Start

Deploy MyCNI into your kubernetes cluster

!!! It will deploy a DaemonSet application in all nodes, please run this in your dev cluster or kind/minikube

kubectl apply -f https://raw.githubusercontent.com/qingwave/mycni/main/deploy/mycni.yaml

Develop

It's more easier to use kind cluster for test. Create a kind cluster

make kind-cluster

Build image

make docker-build

Load image into kind cluster [optional]

make kind-image-load

Deploy CNI

make deploy

mycni's People

Contributors

mayooot avatar qingwave avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mycni's Issues

部署失败

请问一下,deploy/mycni.yaml中的 image: mycni:v1.0, 这个镜像是由自己制作的吗,然后把编译好的mycni、mycnid放进去

Bug

Hi, 大佬,你这有点错,删除ip 的时候也会新建store,dataDir 已经存在,会报错,需要加个判断是否存在
dir := filepath.Join(dataDir, network)
if err := os.MkdirAll(dir, 0755); err != nil {
return nil, err
}

mycni 和 mycnid 重复创建 Bridge

在 mycnid 的 NewReconciler 中创建了自定义网桥。而在 mycni 的cmdAdd 也创建了网桥。

Flannel 插件的流程图里,好像只有在调用 CNI 二进制文件时才创建网桥(如果不存在)。
那么为啥 mycni 和 mycnid 都创建了呢,希望可以解答一下。
image

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.