{"action":"created","issue":{"url":"https://api.github.com/repos/containernetworking/cni/issues/384","repository_url":"https://api.github.com/repos/containernetworking/cni","labels_url":"https://api.github.com/repos/containernetworking/cni/issues/384/labels{/name}","comments_url":"https://api.github.com/repos/containernetworking/cni/issues/384/comments","events_url":"https://api.github.com/repos/containernetworking/cni/issues/384/events","html_url":"https://github.com/containernetworking/cni/pull/384","id":210661641,"number":384,"title":"RFC: CNI Runtime hint: Provide hints regarding the runtime in use","user":{"login":"mcastelino","id":7387737,"avatar_url":"https://avatars1.githubusercontent.com/u/7387737?v=3","gravatar_id":"","url":"https://api.github.com/users/mcastelino","html_url":"https://github.com/mcastelino","followers_url":"https://api.github.com/users/mcastelino/followers","following_url":"https://api.github.com/users/mcastelino/following{/other_user}","gists_url":"https://api.github.com/users/mcastelino/gists{/gist_id}","starred_url":"https://api.github.com/users/mcastelino/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mcastelino/subscriptions","organizations_url":"https://api.github.com/users/mcastelino/orgs","repos_url":"https://api.github.com/users/mcastelino/repos","events_url":"https://api.github.com/users/mcastelino/events{/privacy}","received_events_url":"https://api.github.com/users/mcastelino/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2017-02-28T01:40:03Z","updated_at":"2017-03-22T17:44:02Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/containernetworking/cni/pulls/384","html_url":"https://github.com/containernetworking/cni/pull/384","diff_url":"https://github.com/containernetworking/cni/pull/384.diff","patch_url":"https://github.com/containernetworking/cni/pull/384.patch"},"body":"All main CNI plugins assume they have to deal with namespaces as the primary form of isolation in the case of containers. However with CRI-O adding support for multiple runtimes including virtual machines, it makes sense to provide an option to support these runtimes without breaking backward compatibility.\r\n\r\nhttps://github.com/kubernetes/kubernetes/pull/40662\r\n\r\nIn the case of runtimes that use virtual machines as the isolation implementation, this information can be passed into CNI as an ***optional*** parameter.  \r\n\r\nThe VM runtimes have tried to address this by using integration bridges in some cases. However this approach does not always work (e.g macvlan)\r\n\r\nWhen the runtime hint is present the network plugin can choose an interface setup that is optimal for that runtime type. The plugin is free to completely ignore the hint and assume it only supports namespace centric runtimes. This also means that runtimes should not assume that the hint will result in a interface that is optimal, and will need to handle the cases where a namespace friendly interface is created.\r\n\r\nThis is by no means mandatory and the runtime should be able to detect and support the case where an namespace centic interface is created.\r\n\r\nThis PR attempts to seek feedback on this approach using the bridge plugin.\r\n\r\nIf this runtime hint CNI_RUNTIME_TYPE is acceptable I will add support for the same for all other plugins.\r\n\r\nFor a quick test to observe the default behavior vs the behavior when the hint is accepted.\r\n\r\n```\r\nsudo CNI_PATH=$CNI_PATH CNI_RUNTIME_TYPE=\"vm\" ./priv-net-run.sh ip -d l\r\nsudo CNI_PATH=$CNI_PATH ./priv-net-run.sh ip -d l\r\n\r\n```\r\n\r\ncc @sameo @mrunalp @thockin"},"comment":{"url":"https://api.github.com/repos/containernetworking/cni/issues/comments/288481213","html_url":"https://github.com/containernetworking/cni/pull/384#issuecomment-288481213","issue_url":"https://api.github.com/repos/containernetworking/cni/issues/384","id":288481213,"user":{"login":"mcastelino","id":7387737,"avatar_url":"https://avatars1.githubusercontent.com/u/7387737?v=3","gravatar_id":"","url":"https://api.github.com/users/mcastelino","html_url":"https://github.com/mcastelino","followers_url":"https://api.github.com/users/mcastelino/followers","following_url":"https://api.github.com/users/mcastelino/following{/other_user}","gists_url":"https://api.github.com/users/mcastelino/gists{/gist_id}","starred_url":"https://api.github.com/users/mcastelino/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mcastelino/subscriptions","organizations_url":"https://api.github.com/users/mcastelino/orgs","repos_url":"https://api.github.com/users/mcastelino/repos","events_url":"https://api.github.com/users/mcastelino/events{/privacy}","received_events_url":"https://api.github.com/users/mcastelino/received_events","type":"User","site_admin":false},"created_at":"2017-03-22T17:44:01Z","updated_at":"2017-03-22T17:44:01Z","body":"@bboreham I am working on using plugin chaining to setup the tap interfaces in a separate plugin. However in some cases like macvlan, ipvlan it may not be possible to split the creation of the tap interface using the plugin chaining mechanism. Hence the kernel patches."}}
{"actor":{"display_login":"mcastelino"}}