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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add k8s-pure cni #67

Merged
merged 4 commits into from
Apr 26, 2020
Merged

add k8s-pure cni #67

merged 4 commits into from
Apr 26, 2020

Conversation

ChenLingPeng
Copy link
Contributor

Signed-off-by: forrestchen forrestchen@tencent.com

@chenchun
Copy link
Contributor

Tests failed.

Signed-off-by: forrestchen <forrestchen@tencent.com>
@ChenLingPeng
Copy link
Contributor Author

Fixed

Signed-off-by: forrestchen <forrestchen@tencent.com>
Signed-off-by: forrestchen <forrestchen@tencent.com>
@@ -137,6 +137,9 @@ func CmdAdd(cmdArgs *skel.CmdArgs, networkInfos []*NetworkInfo) (types.Result, e
for idx, networkInfo := range networkInfos {
//append additional args from network info
cmdArgs.Args = strings.TrimRight(fmt.Sprintf("%s;%s", cmdArgs.Args, BuildCNIArgs(networkInfo.Args)), ";")
if result != nil {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个改动哪里用到了吗?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不过不用删

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

参考多cni格式,后面改造可能会用到

if err := json.Unmarshal(args.StdinData, &conf); err != nil {
return fmt.Errorf("conf error: %v", err)
}
vlanIds, results, err := ipam.Allocate(conf.IPAM.Type, args)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

还是调用一次这个veth插件配置多个网卡?可以以后再改吧

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

是的,不然这里涉及到的改动太多,方案也还需讨论

runtime.LockOSThread()
}

func main() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

改下文档supported-cnis.md,简单介绍下怎么使用这个cni插件吗?比如需要管理员自己把vlan网卡和路由配置好

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

好的

Signed-off-by: forrestchen <forrestchen@tencent.com>
@chenchun chenchun merged commit 988a433 into tkestack:master Apr 26, 2020
@chenchun chenchun added this to the v1.0.4 milestone Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants