From b048162bfb185e19edf37cdcf0f8a333d27034bb Mon Sep 17 00:00:00 2001 From: Tomofumi Hayashi Date: Fri, 6 Dec 2019 16:23:10 +0900 Subject: [PATCH] bug 1777206 Fix the process how to add interfaces Currently multus-cni only supports to add interface to pod at creation. Once created pod, multus-cni does not modify interfaces. This change fix the document to align it, i.e. use 'oc create -f' command, not 'oc edit'. --- modules/nw-multus-add-pod.adoc | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/modules/nw-multus-add-pod.adoc b/modules/nw-multus-add-pod.adoc index 36432fc577..116603108b 100644 --- a/modules/nw-multus-add-pod.adoc +++ b/modules/nw-multus-add-pod.adoc @@ -30,17 +30,9 @@ endif::sriov[] .Procedure -To add a Pod to an additional network, complete the following steps: +To add a Pod with additional networks, complete the following steps: -. Edit the Pod resource definition. If you are editing an existing Pod, run the -following command to edit its definition in the default editor. Replace `` -with the name of the Pod to edit. -+ ----- -$ oc edit pod ----- - -. In the Pod resource definition, add the `k8s.v1.cni.cncf.io/networks` +. Create the Pod resource definition and add the `k8s.v1.cni.cncf.io/networks` parameter to the Pod `metadata` mapping. The `k8s.v1.cni.cncf.io/networks` accepts a comma separated string of one or more NetworkAttachmentDefinition Custom Resource (CR) names: + @@ -73,6 +65,12 @@ spec: image: centos/tools ---- +. Create the Pod by running the following command: ++ +---- +$ oc create -f pod.yaml +---- + . Optional: Confirm that the annotation exists in the Pod CR by running the following command. Replace `` with the name of the Pod. +