Giter VIP home page Giter VIP logo

proxmox_vswrouter's Introduction

Proxmox vSW-Router

What is it?

A web-based container-ready Virtual Router project primarily (but not exclusively!) for Proxmox environments, suitable for creating lab networks easily via a web interface.

This project is not associated with the official Proxmox project, however it is very much intended to be complimentary in that it provides a soft router platform which is intended to be easily run as a lightweight container or VM-based Proxmox-friendly virtual router layer for Virtualized environments.

If this project goal interests you and you have further questions, feel free to read through the FAQ which may cover your question in more detail.

Project Aim:

  • Provide a lightweight container-friendly router instance for Proxmox installs - no need for firmware or interfacing with a proprietary router solution. It can be built on container, VM or hardware devices.
  • Model functionality on the VMWare Workstation VMNet functionality - allow easy spinning up of networks, primarily for lab testing, but with richer functionality and a web interface.

Introduction

The purpose of this project is to put together a particular network pattern useful for quickly spinning up and down virtual networks using more than one Proxmox host. This is to hopefully provide a similar ease of use to VMWare VMNet interfaces in VMWare workstation, but without the limitations of single-host virtual networking.

To do this, we offer a simple web interface with the following features:

  1. Add VLAN interfaces with a given IP address using OpenVSwitch internal interfaces
  2. Setting a routing table per interface (if desired) and allowing or denying Internet access per interface

Design

Implementing this project consists of a pair of OpenVSwitch switches, one (or more) on each Proxmox node in the cluster, and one (or more) within a VM. The Proxmox VMs trunk VLANs from their ovs switch to the VM, which acts as a router.

Setup

The following steps will get you up and running:

  1. Deploy an Ubuntu 20.04 Container or VM. The following configuration should be used:

    • VM CPU Cores: 1
    • RAM: Minimum 512MB
    • Network Interfaces: 2 interfaces
      • Interface 1: Management. Should be in VLAN 1

You should deploy 2 Containers or VMs if you are running in HA mode. Keep in mind, HA mode needs to be running across two different Proxmox cluster nodes

  1. Install the following packages: apt-get install apache2 libapache2-mod-php7.4 php7.4-mbstring php7.4-sqlite

    • If you would like VPN functionality, add the following packages:
      • apt-get install openssl openvpn
  2. Clone this git repository under /var/www/html

cd /var/www/html
rm index.html
git clone https://github.com/ngardiner/proxmox_vswrouter .
chown -R www-data:www-data /var/www/html
  1. Enable PHP and restart apache
a2enmod php7.4
service apache2 restart
  1. Access the web interface at http://[ip address]/

  2. Go to the settings tab. This is where you can configure the vswitches that will be used.

    • Your installation, whether Single or Double (Q-in-Q) VLAN tagged will have one VLAN Trunk. Create it first.
    • You are then able to create Q-in-Q switches and connect them to VLANs on the VLAN Trunk switch.
  3. Enable the cron script which will configure all of the settings

cd /var/www/html
cp docs/cron.conf /etc/cron.d/pvsw_agent

Current Status

  • Bridges
    • New bridge - implemented
    • Delete bridge - not implemented
  • Interfaces
    • Create VLAN IP interfaces - implemented (non-HA only)
    • Delete VLAN IP interfaces - implemented (non-HA only)
    • Update incorrect IP address - implemented (non-HA only)
  • Routing Tables
    • Define routing table - implemented
    • Define routing table routes - not implemented
    • Enforce routing table - not implemented
  • VPN
    • Define VPN configuration - in progress
    • Restart on VPN reconfiguration - not implemented

proxmox_vswrouter's People

Contributors

ngardiner avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.