This repository was archived by the owner on Apr 8, 2025. It is now read-only.
File tree 3 files changed +15
-15
lines changed
3 files changed +15
-15
lines changed Original file line number Diff line number Diff line change 13
13
#
14
14
15
15
scriptpath=$GOPATH /src/github.com/containernetworking/cni/scripts
16
- echo $scriptpath
16
+ echo " $scriptpath "
17
17
18
- contid=$( docker run -d --net=none $@ /bin/sleep 10000000)
19
- pid=$( docker inspect -f ' {{ .State.Pid }}' $contid )
18
+ contid=$( docker run -d --net=none " $@ " /bin/sleep 10000000)
19
+ pid=$( docker inspect -f ' {{ .State.Pid }}' " $contid " )
20
20
netnspath=/proc/$pid /ns/net
21
21
22
- $scriptpath /exec-plugins.sh add $contid $netnspath
22
+ " $scriptpath " /exec-plugins.sh add " $contid " " $netnspath "
23
23
24
24
function cleanup() {
25
- $scriptpath /exec-plugins.sh del $contid $netnspath
26
- docker rm -f $contid > /dev/null
25
+ " $scriptpath " /exec-plugins.sh del " $contid " " $netnspath "
26
+ docker rm -f " $contid " > /dev/null
27
27
}
28
28
trap cleanup EXIT
29
29
@@ -35,7 +35,7 @@ trucContid=${contid:0:12}
35
35
docker run -i -t -v /var/lib/cni/usrspcni/shared:/var/lib/cni/usrspcni/shared:rw \
36
36
-v /dev/hugepages:/dev/hugepages \
37
37
dpdk-app-testpmd testpmd -l 0-1 -n 4 -m 1024 --no-pci \
38
- --vdev=virtio_user0,path=/var/lib/cni/usrspcni/shared/$trucContid -eth0 \
38
+ --vdev=virtio_user0,path=/var/lib/cni/usrspcni/shared/" $trucContid " -eth0 \
39
39
--file-prefix=container \
40
40
-- -i --txqflags=0xf00 --disable-hw-vlan --port-topology=chained
41
41
Original file line number Diff line number Diff line change 17
17
#
18
18
19
19
scriptpath=$GOPATH /src/github.com/containernetworking/cni/scripts
20
- echo $scriptpath
20
+ echo " $scriptpath "
21
21
22
- contid=$( docker run -d --net=none $@ /bin/sleep 10000000)
23
- pid=$( docker inspect -f ' {{ .State.Pid }}' $contid )
22
+ contid=$( docker run -d --net=none " $@ " /bin/sleep 10000000)
23
+ pid=$( docker inspect -f ' {{ .State.Pid }}' " $contid " )
24
24
netnspath=/proc/$pid /ns/net
25
25
26
- $scriptpath /exec-plugins.sh add $contid $netnspath
26
+ " $scriptpath " /exec-plugins.sh add " $contid " " $netnspath "
27
27
28
28
function cleanup() {
29
- $scriptpath /exec-plugins.sh del $contid $netnspath
30
- docker rm -f $contid > /dev/null
29
+ " $scriptpath " /exec-plugins.sh del " $contid " " $netnspath "
30
+ docker rm -f " $contid " > /dev/null
31
31
}
32
32
trap cleanup EXIT
33
33
34
34
docker run \
35
35
-v /var/lib/cni/usrspcni/shared:/var/lib/cni/usrspcni/shared:rw \
36
- -v /var/lib/cni/usrspcni/$contid :/var/lib/cni/usrspcni/data:rw \
36
+ -v /var/lib/cni/usrspcni/" $contid " :/var/lib/cni/usrspcni/data:rw \
37
37
--device=/dev/hugepages:/dev/hugepages \
38
- --net=container:$contid $@
38
+ --net=container:" $contid " " $@ "
39
39
You can’t perform that action at this time.
0 commit comments