aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorVratko Polak <vrpolak@cisco.com>2020-06-25 15:06:00 +0200
committerPeter Mikus <pmikus@cisco.com>2020-06-30 06:58:42 +0000
commit6df4bfc3beb52047e582d2c6cf2cbc96a4d34773 (patch)
treedc5a9f9a2dc954f44c68ff5b7861fa86a7bdf1e0 /docs
parent3a97223e49e848614fcd3881ded46d147d36af82 (diff)
Report: Improve containers.rst
Change-Id: I2280b3f8c1977b47b222fa5ce3d47f90dc9b7e87 Signed-off-by: Vratko Polak <vrpolak@cisco.com>
Diffstat (limited to 'docs')
-rw-r--r--docs/report/vpp_performance_tests/documentation/containers.rst80
1 files changed, 40 insertions, 40 deletions
diff --git a/docs/report/vpp_performance_tests/documentation/containers.rst b/docs/report/vpp_performance_tests/documentation/containers.rst
index c9ed64ab06..14817df64f 100644
--- a/docs/report/vpp_performance_tests/documentation/containers.rst
+++ b/docs/report/vpp_performance_tests/documentation/containers.rst
@@ -146,13 +146,13 @@ Docker
Docker builds on top of Linux kernel containment features, and
offers a high-level tool for wrapping the processes, maintaining and
-executing them in containers [docker]_. Currently it using *runc* a CLI tool for
-spawning and running containers according to the `OCI specification
-<https://www.opencontainers.org/>`_
+executing them in containers [docker]_. Currently it is using *runc*,
+a CLI tool for spawning and running containers according to the
+`OCI specification <https://www.opencontainers.org/>`_.
A Docker container image is a lightweight, stand-alone, executable
-package of a piece of software that includes everything needed to run
-it: code, runtime, system tools, system libraries, settings.
+package that includes everything needed to run the container:
+code, runtime, system tools, system libraries, settings.
CSIT uses Docker to manage the maintenance and execution of
containerized applications used in CSIT performance tests.
@@ -225,13 +225,13 @@ Current CSIT implementation is illustrated using UML Class diagram:
|
+----------+---------+
| |
- +------+-------+ +------+-------+
- | LXC | | Docker |
- +--------------+ +--------------+
- | (inherinted) | | (inherinted) |
- +------+-------+ +------+-------+
- | |
- +---------+---------+
+ +------+------+ +------+------+
+ | LXC | | Docker |
+ +-------------+ +-------------+
+ | (inherited) | | (inherited) |
+ +------+------+ +------+------+
+ | |
+ +----------+---------+
|
| constructs
|
@@ -323,38 +323,38 @@ variables and no methods except overriden ``__getattr__`` and ``__setattr__``.
Instance variables are assigned to container dynamically during the
``construct_container(**kwargs)`` call and are passed down from the RF keyword.
-Usage example:
+There is no parameters check functionality. Passing the correct arguments
+is a responsibility of the caller.
+
+Examples
+~~~~~~~~
+
+This section contains a high-level example of multiple initialization steps
+via ContainerManager; taken from an actual CSIT code,
+but with non-code lines (comments, Documentation) removed for brevity.
+
+:
.. code-block:: robotframework
- | Construct VNF containers on all DUTs
- | | [Arguments] | ${technology} | ${image} | ${cpu_count}=${1} | ${count}=${1}
- | | ...
- | | ${group}= | Set Variable | VNF
- | | ${skip_cpus}= | Evaluate | ${vpp_cpus}+${system_cpus}
+ | Start containers for test
+ | | [Arguments] | ${dut}=${None} | ${nf_chains}=${1} | ${nf_nodes}=${1}
+ | | ... | ${auto_scale}=${True} | ${pinning}=${True}
+ | |
+ | | Set Test Variable | @{container_groups} | @{EMPTY}
+ | | Set Test Variable | ${container_group} | CNF
+ | | Set Test Variable | ${nf_nodes}
| | Import Library | resources.libraries.python.ContainerUtils.ContainerManager
- | | ... | engine=${container_engine} | WITH NAME | ${group}
- | | ${duts}= | Get Matches | ${nodes} | DUT*
- | | :FOR | ${dut} | IN | @{duts}
- | | | ${env}= | Create List | DEBIAN_FRONTEND=noninteractive
- | | | ${mnt}= | Create List | /tmp:/mnt/host | /dev:/dev
- | | | ${cpu_node}= | Get interfaces numa node | ${nodes['${dut}']}
- | | | ... | ${dut1_if1} | ${dut1_if2}
- | | | Run Keyword | ${group}.Construct containers
- | | | ... | name=${dut}_${group} | node=${nodes['${dut}']} | mnt=${mnt}
- | | | ... | image=${container_image} | cpu_count=${container_cpus}
- | | | ... | cpu_skip=${skip_cpus} | cpuset_mems=${cpu_node}
- | | | ... | cpu_shared=${False} | env=${env} | count=${container_count}
- | | | ... | install_dkms=${container_install_dkms}
- | | Append To List | ${container_groups} | ${group}
-
-Mandatory parameters to create standalone container are: ``node``, ``name``,
-``image`` [imagevar]_, ``cpu_count``, ``cpu_skip``, ``cpuset_mems``,
-``cpu_shared``.
-
-There is no parameters check functionality. Passing required arguments is in
-coder responsibility. All the above parameters are required to calculate the
-correct cpu placement. See documentation for the full reference.
+ | | ... | engine=${container_engine} | WITH NAME | ${container_group}
+ | | Construct chains of containers
+ | | ... | dut=${dut} | nf_chains=${nf_chains} | nf_nodes=${nf_nodes}
+ | | ... | auto_scale=${auto_scale} | pinning=${pinning}
+ | | Acquire all '${container_group}' containers
+ | | Create all '${container_group}' containers
+ | | Configure VPP in all '${container_group}' containers
+ | | Start VPP in all '${container_group}' containers
+ | | Append To List | ${container_groups} | ${container_group}
+ | | Save VPP PIDs
Kubernetes
~~~~~~~~~~