diff --git a/README.md b/README.md index eee7391d7..2f3658fba 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ The quickstart installation method for Multus requires that you have first insta Clone this GitHub repository, we'll apply a daemonset which installs Multus using to `kubectl` from this repo. From the root directory of the clone, apply the daemonset YAML file: ``` -$ cat ./deployments/multus-daemonset-thick-plugin.yml | kubectl apply -f - +cat ./deployments/multus-daemonset-thick-plugin.yml | kubectl apply -f - ``` This will configure your systems to be ready to use Multus CNI, but, to get started with adding additional interfaces to your pods, refer to our complete [quick-start guide](docs/quickstart.md) diff --git a/docs/how-to-use.md b/docs/how-to-use.md index 95a9222cd..038cc7451 100644 --- a/docs/how-to-use.md +++ b/docs/how-to-use.md @@ -15,13 +15,13 @@ Generally we recommend two options: Manually place a Multus binary in your `/opt You may acquire the Multus binary via compilation (see the [developer guide](development.md)) or download the a binary from the [GitHub releases](https://github.com/k8snetworkplumbingwg/multus-cni/releases) page. Copy multus binary into CNI binary directory, usually `/opt/cni/bin`. Perform this on all nodes in your cluster (master and nodes). - $ cp multus /opt/cni/bin + cp multus /opt/cni/bin *Via Daemonset method* As a [quickstart](quickstart.md), you may apply these YAML files (included in the clone of this repository). Run this command (typically you would run this on the master, or wherever you have access to the `kubectl` command to manage your cluster). - $ cat ./deployments/multus-daemonset.yml | kubectl apply -f - + cat ./deployments/multus-daemonset.yml | kubectl apply -f - If you need more comprehensive detail, continue along with this guide, otherwise, you may wish to either [follow the quickstart guide]() or skip to the ['Create network attachment definition'](#create-network-attachment-definition) section. @@ -34,8 +34,8 @@ You put CNI config file in `/etc/cni/net.d`. Kubernetes CNI runtime uses the alp Execute following commands at all Kubernetes nodes (i.e. master and minions) ``` -$ mkdir -p /etc/cni/net.d -$ cat >/etc/cni/net.d/00-multus.conf </etc/cni/net.d/00-multus.conf < /etc/cni/net.d/multus.d/multus.kubeconfig < /etc/cni/net.d/multus.d/multus.kubeconfig < /etc/cni/multus/net.d/macvlan2.conf +cat < /etc/cni/multus/net.d/macvlan2.conf { "cniVersion": "0.3.0", "type": "macvlan", @@ -268,7 +268,7 @@ $ cat < /etc/cni/multus/net.d/macvlan2.conf ``` # Execute following command at Kubernetes master -$ cat <`. ``` # Execute following command at Kubernetes master -$ cat <"`. ``` # Execute following command at Kubernetes master -$ cat < mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 promiscuity 0 numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535 inet 127.0.0.1/8 scope host lo @@ -529,7 +530,8 @@ EOF This will set `192.168.2.1` as the default route over the `net1` interface, such as: ``` -$ kubectl exec -it samplepod -- ip route +kubectl exec -it samplepod -- ip route + default via 192.168.2.1 dev net1 10.244.0.0/24 dev eth0 proto kernel scope link src 10.244.0.169 10.244.0.0/16 via 10.244.0.1 dev eth0 diff --git a/docs/quickstart.md b/docs/quickstart.md index d56bc93f2..3c49fc291 100644 --- a/docs/quickstart.md +++ b/docs/quickstart.md @@ -51,7 +51,7 @@ git clone https://github.com/k8snetworkplumbingwg/multus-cni.git && cd multus-cn We'll apply a YAML file with `kubectl` from this repo. ``` -$ cat ./deployments/multus-daemonset-thick-plugin.yml | kubectl apply -f - +cat ./deployments/multus-daemonset-thick-plugin.yml | kubectl apply -f - ``` ### What the Multus daemonset does @@ -66,7 +66,7 @@ $ cat ./deployments/multus-daemonset-thick-plugin.yml | kubectl apply -f - Generally, the first step in validating your installation is to ensure that the Multus pods have run without error, you may see an overview of those by looking at: ``` -$ kubectl get pods --all-namespaces | grep -i multus +kubectl get pods --all-namespaces | grep -i multus ``` You may further validate that it has ran by looking at the `/etc/cni/net.d/` directory and ensure that the auto-generated `/etc/cni/net.d/00-multus.conf` exists corresponding to the alphabetically first configuration file. @@ -176,7 +176,7 @@ EOF You may now inspect the pod and see what interfaces are attached, like so: ``` -$ kubectl exec -it samplepod -- ip a +kubectl exec -it samplepod -- ip a ``` You should note that there are 3 interfaces: