mirror of https://github.com/EdgeVPNio/tools.git
Update for Ubuntu20
parent
cd6cd9e07c
commit
e0df633e64
|
@ -1,2 +1,3 @@
|
|||
# tools
|
||||
Various development tools used with EdgeVPNio software
|
||||
# EdgeVPNio tools
|
||||
|
||||
Various management and configuration tools used with EdgeVPNio software development.
|
||||
|
|
|
@ -1,12 +1,14 @@
|
|||
# EdgeVPNio DEBIAN PACKAGE
|
||||
|
||||
The Debian package installs EdgeVPNio (evio) as a systemd service and is supported in Ubuntu 18.04 and Raspberry Pi Raspbian OS. Use the following procedure to create a new installer package.
|
||||
1. Clone the `tools` repo and use `tools/deb-pak` as your base directory.
|
||||
|
||||
1. Clone the `tools` repo and use `tools/debian-package` as your base directory.
|
||||
2. Copy the `tincan` executable, and the contents of the `controller` folder into `edge-vpnio/opt/edge-vpnio`.
|
||||
3. Copy `config.json`, the template or completed file, into `edge-vpnio/etc/opt/edge-vpnio`.
|
||||
4. Execute `./deb-gen` to create the `edge-vpnio.deb` installer package.
|
||||
|
||||
By default, the following files and directories are created:
|
||||
Installation creates the following files and directories:
|
||||
|
||||
1. `/opt/edge-vpnio/tincan`
|
||||
2. `/opt/edge-vpnio/controller/`
|
||||
3. `/etc/opt/edge-vpnio/config.json`
|
||||
|
@ -14,7 +16,6 @@ By default, the following files and directories are created:
|
|||
5. `/var/logs/edge-vpnio/tincan_log`
|
||||
6. `/var/logs/edge-vpnio/ctrl.log`
|
||||
|
||||
The installer has dependencies on, and will install `python3`, `python3-pip`, `iproute2`, `openvswitch-switch`, `bridge-utils`.
|
||||
To install EdgeVPNio invoke `sudo apt install -y <path/to/installer>/edge-vpnio.deb`.
|
||||
After installation but before starting evio, complete `config.json` by adding the XMPP credentials, setting the IP address, and applying other configurations as needed.
|
||||
Then start evio using `sudo systemctl start evio`.
|
||||
|
|
|
@ -7,13 +7,11 @@ Version: 20.7
|
|||
Maintainer: <ip.over.p2p@gmail.com>
|
||||
Architecture: $(dpkg --print-architecture)
|
||||
Homepage: http://edgevpnio.github.io
|
||||
Depends: python3, python3-dev, python3-pip, iproute2, openvswitch-switch, bridge-utils
|
||||
Description: Virtual Overlay Networks.
|
||||
Depends: python3.8, python3-dev, python3-venv, python3-pip, iproute2, openvswitch-switch, bridge-utils
|
||||
Description: Virtual Overlay Networking.
|
||||
EdgeVPN is an open-source user-centric software virtual network allowing end users to define and create their own virtual private networks (VPNs). EdgeVPNio virtual networks provide end-to-end tunneling of IP or Ethernet over Tincan links setup and managed through a control API to create various software-defined VPN overlays.
|
||||
Tag: P2P Overlay Networking
|
||||
!
|
||||
|
||||
mkdir -p edge-vpnio/etc/opt/edge-vpnio && \
|
||||
cp edge-vpnio/opt/edge-vpnio/template-config.json edge-vpnio/etc/opt/edge-vpnio/config.json && \
|
||||
dpkg-deb --build --root-owner-group edge-vpnio .
|
||||
rm -f edge-vpnio/DEBIAN/control edge-vpnio/etc/opt/edge-vpnio/config.json
|
||||
dpkg-deb --build --root-owner-group edge-vpnio .
|
||||
rm -f edge-vpnio/DEBIAN/control
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
#!/bin/bash
|
||||
|
||||
cd /opt/edge-vpnio
|
||||
pip3 --no-cache-dir install virtualenv
|
||||
virtualenv --python=python3.6 venv
|
||||
python3 -m venv venv
|
||||
source venv/bin/activate
|
||||
pip3 --no-cache-dir install psutil sleekxmpp requests simplejson ryu
|
||||
pip3 --no-cache-dir install wheel psutil slixmpp requests simplejson ryu
|
||||
deactivate
|
||||
systemctl daemon-reload
|
||||
systemctl enable evio
|
|
@ -6,8 +6,8 @@ RUN apt-get update -y && apt-get install -y \
|
|||
psmisc \
|
||||
iputils-ping \
|
||||
nano \
|
||||
python3.6 \
|
||||
python3.6-dev \
|
||||
python3.8 \
|
||||
python3-dev \
|
||||
python3-pip \
|
||||
python3-venv \
|
||||
iproute2 \
|
||||
|
|
|
@ -5,5 +5,5 @@ mkdir -p /opt/edge-vpnio && \
|
|||
cd /opt/edge-vpnio && \
|
||||
python3 -m venv venv && \
|
||||
source venv/bin/activate && \
|
||||
pip3 --no-cache-dir install psutil sleekxmpp requests simplejson ryu && \
|
||||
pip3 --no-cache-dir install wheel psutil slixmpp requests simplejson ryu && \
|
||||
deactivate
|
||||
|
|
53
setup
53
setup
|
@ -2,21 +2,24 @@
|
|||
|
||||
EVIO=https://github.com/EdgeVPNio/evio.git
|
||||
EXLIBS=https://github.com/ipop-project/3rd-Party-Libs.git
|
||||
PYVER=3.6
|
||||
PY=python3.8
|
||||
|
||||
function install_build_tools
|
||||
{
|
||||
sudo bash -c "
|
||||
apt-get update -y && \
|
||||
apt-get install -y build-essential"
|
||||
apt-get install -y git \
|
||||
make clang libc++-dev libssl-dev $PY"
|
||||
}
|
||||
|
||||
function pull_src
|
||||
{
|
||||
wd=$(pwd)
|
||||
cd ..
|
||||
#stat evio dir clone or pull
|
||||
git clone $EVIO
|
||||
cd evio/tincan/external
|
||||
#
|
||||
git clone -b ubuntu-x64 --single-branch https://github.com/ipop-project/3rd-Party-Libs.git
|
||||
cd $wd
|
||||
}
|
||||
|
@ -31,25 +34,36 @@ function make_tincan
|
|||
|
||||
function make_debpak
|
||||
{
|
||||
cp -r ../evio/controller/* debian-package/edge-vpnio/opt/edge-vpnio/ && \
|
||||
cp ../evio/tincan/trunk/out/release/x86_64/tincan debian-package/edge-vpnio/opt/edge-vpnio/ && \
|
||||
chmod +x debian-package/edge-vpnio/opt/edge-vpnio/tincan && \
|
||||
wd=$(pwd) && cd debian-package/ && \
|
||||
./deb-gen && \
|
||||
rm -rf edge-vpnio/opt/edge-vpnio/framework \
|
||||
edge-vpnio/opt/edge-vpnio/modules \
|
||||
edge-vpnio/opt/edge-vpnio/tincan \
|
||||
edge-vpnio/opt/edge-vpnio/template-config.json \
|
||||
edge-vpnio/opt/edge-vpnio/Controller.py && \
|
||||
cd $wd
|
||||
wd=$(pwd)
|
||||
cp ../evio/controller/Controller.py debian-package/edge-vpnio/opt/edge-vpnio/ && \
|
||||
mkdir -p debian-package/edge-vpnio/etc/opt/edge-vpnio/
|
||||
cp ../evio/controller/template-config.json debian-package/edge-vpnio/etc/opt/edge-vpnio/config.json && \
|
||||
cp -r ../evio/controller/modules/ ../evio/controller/framework/ debian-package/edge-vpnio/opt/edge-vpnio/ && \
|
||||
chmod 0775 debian-package/edge-vpnio/opt/edge-vpnio/framework/ && \
|
||||
chmod 0664 debian-package/edge-vpnio/opt/edge-vpnio/framework/* && \
|
||||
chmod 0775 debian-package/edge-vpnio/opt/edge-vpnio/modules/ && \
|
||||
chmod 0664 debian-package/edge-vpnio/opt/edge-vpnio/modules/* && \
|
||||
chmod 0664 debian-package/edge-vpnio/opt/edge-vpnio/Controller.py && \
|
||||
chmod 0664 debian-package/edge-vpnio/etc/opt/edge-vpnio/config.json && \
|
||||
cp ../evio/tincan/trunk/out/release/x86_64/tincan debian-package/edge-vpnio/opt/edge-vpnio/ && \
|
||||
chmod 0775 debian-package/edge-vpnio/opt/edge-vpnio/tincan && \
|
||||
cd debian-package/ && \
|
||||
./deb-gen && \
|
||||
rm -rf edge-vpnio/opt/edge-vpnio/framework \
|
||||
edge-vpnio/opt/edge-vpnio/modules \
|
||||
edge-vpnio/opt/edge-vpnio/tincan \
|
||||
edge-vpnio/opt/edge-vpnio/template-config.json \
|
||||
edge-vpnio/opt/edge-vpnio/Controller.py \
|
||||
edge-vpnio/etc/opt/edge-vpnio/config.json
|
||||
cd $wd
|
||||
}
|
||||
|
||||
function make_testbed_prereqs
|
||||
function install_testbed_deps
|
||||
{
|
||||
sudo bash -c "
|
||||
apt-get update -y && \
|
||||
apt-get install -y openvswitch-switch \
|
||||
python$PYVER python3-pip python3-venv python3-dev \
|
||||
$PY python3-pip python3-venv python3-dev \
|
||||
apt-transport-https \
|
||||
ca-certificates \
|
||||
curl git \
|
||||
|
@ -71,7 +85,7 @@ function make_venv
|
|||
{
|
||||
wd=$(pwd)
|
||||
cd testbed && \
|
||||
python$PYVER -m venv venv && \
|
||||
$PY -m venv venv && \
|
||||
source venv/bin/activate && \
|
||||
pip3 install simplejson
|
||||
cd $wd
|
||||
|
@ -81,7 +95,7 @@ function make_dkrimg
|
|||
{
|
||||
mv debian-package/edge-vpnio_20.7_amd64.deb docker-image/ && \
|
||||
docker build -f ./docker-image/evio-base.Dockerfile -t edgevpnio/evio-base:1.0 ./docker-image && \
|
||||
docker build -f ./docker-image/evio-node.Dockerfile -t edgevpnio/evio-node:20.7 ./docker-image
|
||||
docker build -f ./docker-image/evio-node.Dockerfile -t edgevpnio/evio-node:20.7.3 ./docker-image
|
||||
|
||||
}
|
||||
|
||||
|
@ -143,6 +157,9 @@ function do_full_setup
|
|||
}
|
||||
|
||||
case $1 in
|
||||
deps)
|
||||
install_build_tools
|
||||
;;
|
||||
src)
|
||||
pull_src
|
||||
;;
|
||||
|
@ -156,7 +173,7 @@ case $1 in
|
|||
make_dkrimg
|
||||
;;
|
||||
testbed)
|
||||
make_testbed_prereqs
|
||||
install_testbed_deps
|
||||
;;
|
||||
venv)
|
||||
make_venv
|
||||
|
|
Loading…
Reference in New Issue