Architecture

Components

The project is founded on Docker containers. It contains several components (GUI, router instances, client instances) which all are dockerized. The project heavily relies on Docker in Docker (see Docker Hub) technology. The following figure presents the components, their relations and overall concept of the system.

GUI

The GUI is a core component of the system. It is a dockerized Django webapp which runs on top of the Docker in Docker container image. The GUI provides a webpage allowing you to configure your simulation environment. Apart from that, it has also a capability of instantiation of the configured environment, as it is using Docker in Docker technology.

The instantiation procedure heavily relies on Docker Compose (see the docs). Basically, containers are run through Docker Compose and later on the initial configuration is injected. The teardown procedure solely relies on Docker Compose. Moreover, this technology is used to virtualize networks for the environment, to provision containers with suitable network interfaces, and to inject some basic configuration. The script providing rest of the initial configuration heavily relies on the configuration provided by the Docker Compose facilities. But be aware that user of this project does not have to do anything with the Docker Compose - GUI container has Docker Compose installed and does not require any work from you. If you are interested in the internals more, see the Advanced Topics section.

The GUI itself is based on templating. Configuration created by you goes through a templating engine (see jinja) which allows generating files required by the Docker Compose, VyOS configuration files, setup scripts, client Buildfile, and more. All the generated sources are build the project which you can download, modify and run on different computers. If you are interested in that topic, you may find some insights at the Advanced Topics section.

The graphical component allowing you configure the environment is based on the vis.js library (see http://visjs.org/). The configuration you create is translated by the GUI to the design file which is used further in the environment generation process. The design file can also be downloaded and uploaded so that you can save the results of your work for future use.

Router

Router are simulated using VyOS (see vyos.net) which has the capabilities of software implemented router. We provide container image with VyOS installed, and initial configuration is injected during the environment initialisation. When the environment is running the router container has all interfaces configured and available. You can play with this configuration freely (more on this topic in User Guide).

Router containers have statically assigned memory limits and CPU shares, so you could more reliably profile your environment.

Client

The client is simulated with Ubuntu container. The system has all the interfaces configured, and connections to the routers (added through GUI) are already working. Client container image is customised by us (for example ssh was configured) and the Docker Buildfile for that image is a part of the project you can download from the GUI. This enables you to customise your clients further (for example, you may want to have traceroute installed for all your clients). Guidelines how to achieve this can be found in the Advanced Topics section.

Docker in Docker

The GUI is able to instantiate your environment by launching sibling containers. This design allows to virtualize large networks with minimal resource consumption (as the containers are lightweight) and at the same time to isolate your machine from the simulated network.

Action Flow

The following Figure presents what happens upon actions taken by the user. Some parts are simplified, and webpage updates are omitted. Some topics were mentioned earlier, but the figure may make them clearer.

results matching ""

    No results matching ""