networking: Add flags to specify net config and net plugin binary dirs. #2270
Conversation
Add `--net-config` for net config dir. Add `--net-plugin` for net plugin binary dir. Also did minor refactoring that groups networking related flags together.
So for the tests, I am trying to copy some plugin binary to a random directory, change its name, and use So where should I copy the plugin binary from? |
|
||
// Copy and rename the bridge plugin. | ||
// Note that this assumes the 'bridge' plugin locates in build-rkt-${tag}/tools. | ||
if err := os.Link(path.Join(ctx.RktBin(), "..", "..", "..", "tools", "bridge"), path.Join(netPluginDir, "test-bridge")); err != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@krnowak Could you think of any better way to locate the plugin binary?
@yifan-gu: My idea was to split stage0 and stage1 config as per #2013. So, stage1 config could allow user to specify net plugins paths and CNI config (in a bit different, but consistent format). This, together with passing user config to stage1 should fix your issue too. I'm not fond of the |
For the record - my work is here - https://github.com/kinvolk/rkt/tree/krnowak/config-split-backward-compatible |
So are we going to get that in for 1.2 or next release? @krnowak |
@yifan-gu: For the next one. |
Here is the preliminary PR that implements the feature - #2312 |
Should this be closed in favour of #2312? |
Yes. |
Add
--net-config
for net config dir.Add
--net-plugin
for net plugin binary dir.Also did minor refactoring that groups networking related flags together.
cc @iaguis @alban @jonboulle