Skip to content

Latest commit

 

History

History
297 lines (228 loc) · 14.2 KB

README.md

File metadata and controls

297 lines (228 loc) · 14.2 KB

Contributors Forks Stargazers Issues MIT License


Logo

AUTOMATING THE DEPLOYMENT OF NETWORK SETUPS USING VAGRANT

Design of Networks and communication systems - Project A.Y. 2020-21 University of Trento, Italy
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact

About The Project

Main window screenshot

This project is based on a graphical user interface (GUI) that provides a platform for the developer to create a fully automated virtual network environment for testing and development. The users can easily customize and design a virtual network environment according to their needs. With the help of this platform, a user can create and configure different virtual machines acting as a server, router, switches, and hosts or specialized hosts. Custom topologies can be designed from scratch or starting from predefined templates. Once the network is deployed and configured, the user can access or monitor each virtual machine.

Dashboard

A monitoring dashboard is configured and deployed in order to provide users an extended view of the single virtual machine status. The configuration of the dashboard is based on a specific data flux which is commonly adopted in network configurations:

  • Telegraf collects data from the target node and sends it to a specific end-point via http requests;
  • Influxdb receives the data from the target node and stores it in an optimal way;
  • Grafana plots and prompts the data stored in influxdb through a custom dashboard.

Dashboard data flux scheme Dashboard example CPU Dashboard example network

The configuration of this flux is automated as, everytime a network is deployed, an additional vagrant environment is deployed in "Dashboard_server". The machine where grafana server is executed is based on the following Vagrant Box: superbogiuseppe/grafana_server.

Credentials for the dashboard: - Username: admin - Password: dashboard

List of features

Available features:

  • Provide Graphical User Interface for creating Virtual environments;
  • provide a modern monitoring architecture to monitor running virtual environments;
  • Provide the functionality to use different Linux machine's flavors for different purposes;
  • Provide the option to set a specific uplink or downlink speed limit;
  • Provide the option to control your network in real-time;
  • Provide the option to write and debug the vagrant scripts;
  • Provide the option of customizing the network topologies;
  • Provide the option of using different Docker images.

Built With

A network is composed of a set of computing devices connected to each other. Likewise, a graph is a mathematical structure composed of a set of nodes connected among each other via edges. For this reason, the network management core of this project is based on a really light python library called pyvis, which is based on javascript. This library, makes it possible to have a very clear network visualization and all the details of each node collected in the entity itself. In order to monitor the network statistics, we have used (Telegraf, InfluxBD, and Grafana). These technologies are open source and easy to use and implement. They also provide an open platform for beautiful analytics and monitoring (a dashboard for displaying data) from many sources, particularly time-series data. On the backend, we have used the vagrant development environment by HashiCorp along with the VirtualBox. Vagrant is a simple and powerful tool that provides a platform where we can easily integrate our existing configuration management toolings like Ansible, Chef, Docker, Puppet, or Salt.

These tools have not been used in the default topologies that we have created. But users can create and configure custom topologies using these tools easily.

Getting Started

In order to get benefit from this environment, you must have some basic knowledge of networking, python, vagrant configuration, etc.

Prerequisites

Some prerequisites have to be done before using this environment. It's based on your operating system. You can use Windows, Mac, Linux, but you have to see the procedure of installation according to your operating system. We have used the entire windows operating system to develop this environment. But anyone can install it on the other operating system.

Installation Requirements

  1. Python 3.9.0
  2. 10GB disk storage
  3. Windows/Linux/Mac
  4. VirtualBox
  5. Vagrant
  6. Internet
  7. Clone the repo
    git clone https://github.com/SuperboGiuseppe/dncs_lab2.git

Usage

This project is only used to provide the user to test their environments by providing the same operating system, packages, and configurations, all while giving users the flexibility to use their favorite editor, IDE, and browsers. In order to launch the design tool, execute the following command in the main directory of the project:

python ./main.py

Create a new network

By pressing "New network", a wizard will be prompted. Here it is possible to create a network from scratch (Not currently implemented) or to create a network from a template. Once the template has been selected, the same topology will be available on the main canvas and ready to be configured/modified/deployed.

Save network

By pressing "Save network", it is possible to save the network in a html format (Pyvis compatible format) along with its configuration.

Open network

By pressing "Open network", it is possible to import an already configured/designed network. It is necessary that the file is compatible with the pyvis library (HTML format).

Adding new devices (Not currently implemented)

By pressing the buttons "Router", "Switch", "Host" or "Other", it is possible to add a new device to the network.

Edit configuration

By pressing "Edit configuration" it is possible to edit the configuration of each device of the network:

  • Virtual machine characteristics (CPUs, RAM, VM Image, device name);
  • Network configuration of each interface (IP, Netmask, interface name);
  • Custom script to be provisioned during the deployment.

Edge configuration

By pressing "Edge configuration", it is possible to edit uplink and downlink speed limits of each edge.

Deploy network

By pressing "Deploy network", the network will be deployed via Vagrant. It is recommended to have the debug console active in order to retrieve any deployment error or warning.

Control dashboard

Once the network is deployed successfully, by pressing "Control dashboard", it is possible to navigate in the grafana interface in order to visualize any real-time statistic of each machine.

SSH Connection

By pressing "SSH Connection", it is possible to establish an SSH connection with a specific node of the deployed network: a terminal will be prompted once the connection has been established.

Debug console

By pressing "Debug console", it is possible to show/hide the debug console which is useful during the deployment phase of the network.

Turn on/off VMs

By pressing "Turn on/of VMs", it is possible to stop all the devices of the network without destroying them.

Destroy network

By pressing "Destroy network", it is possible to destroy the deployed network along with the dashboard server.

Roadmap

The road map we have:

  • On the Frontend python library called pyvis used.
  • On the backend vagrant scripts used to create the virtual machines.
  • On the backend, we have created a mechanism that converts the Vagrant scripts into the HTML formats in order to be compatible with the pyvis.
  • A virtual machine created separately to manage the dashboard that runs along automatically with vagrant topologies.

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b)
  3. Commit your Changes (git commit -m 'Add some Feature')
  4. Push to the Branch (git push origin Feature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Project coordinator

Students

Project Link: AUTOMATING THE DEPLOYMENT OF NETWORK SETUPS USING VAGRANT