summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorGFdevelop2019-03-13 13:26:56 +0100
committerGFdevelop2019-03-13 13:29:30 +0100
commitcd774c8c0f350f2593d865977ba5b422c157f6f6 (patch)
treea4918b59825b46a86a16e736752ee2d1567402cd
parent851cc46a9fadd1b53e64da001a4479d0305b1e91 (diff)
downloadaur-cd774c8c0f350f2593d865977ba5b422c157f6f6.tar.gz
ADDED: vde2 (no conflict)
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD60
-rw-r--r--dhcpd.conf.sample12
-rw-r--r--iptables.rules.sample5
-rw-r--r--vde-config.sample35
-rw-r--r--vde-connection.sample6
-rw-r--r--vde2.install9
7 files changed, 135 insertions, 15 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c1908a55e75e..4840750587e0 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,38 @@
pkgbase = vdeplug4-git
pkgdesc = VDE: Virtual Distributed Ethernet. Plug your VM directly to the cloud
pkgver = r44.7ebdc73
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/rd235/vdeplug4
+ install = vde2.install
arch = any
groups = view-os
license = GPL2
+ license = LGPL
+ license = CUSTOM
+ makedepends = python
makedepends = s2argv-execs
+ makedepends = libpcap
+ makedepends = openssl
depends = s2argv-execs
+ depends = libpcap
+ depends = openssl
provides = vdeplug4
provides = vde2
conflicts = vdeplug4
conflicts = vde2
+ replaces = vde2
source = git+https://github.com/rd235/vdeplug4.git
- md5sums = SKIP
+ source = git+https://github.com/virtualsquare/vde-2.git
+ source = dhcpd.conf.sample
+ source = iptables.rules.sample
+ source = vde-config.sample
+ source = vde-connection.sample
+ sha256sums = SKIP
+ sha256sums = SKIP
+ sha256sums = da0e2766dc63069da929c28126831ad5fdddcc4a04105a21217d78832c7ca1bc
+ sha256sums = 99076d7466cd99673dbe91ef83865187e7868177959b38e125df63eea957f83e
+ sha256sums = 5727c215646333c37b26388146cd3e6b3814b88d60d54051d7da99e00c0aef87
+ sha256sums = 5139110ed6d5d1174bf12971512dac5196d9d07df46dd393d7b1cd083118fe9b
pkgname = vdeplug4-git
diff --git a/PKGBUILD b/PKGBUILD
index e4d1eec2b6a4..2a82f48a7a82 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,22 +1,40 @@
# Maintainer: Gabriele Fulgaro <gabriele.fulgaro@gmail.com>
+# Contributor: Sergej Pupykin
+# Contributor: Tobias Powalowski <tpowa@archlinux.org>
_pkgname="vdeplug4"
+_pkgname2="vde2"
pkgname="$_pkgname-git"
pkgver=r44.7ebdc73
-pkgrel=1
+pkgrel=2
pkgdesc="VDE: Virtual Distributed Ethernet. Plug your VM directly to the cloud"
-arch=(any)
+arch=('any')
url="https://github.com/rd235/$_pkgname"
-license=('GPL2')
-groups=("view-os")
-depends=('s2argv-execs')
-makedepends=('s2argv-execs')
-provides=("$_pkgname" 'vde2')
-conflicts=("$_pkgname" 'vde2')
-replace=('vde2')
-source=("git+$url.git")
-md5sums=('SKIP')
+license=('GPL2' 'LGPL' 'CUSTOM')
+groups=('view-os')
+depends=('s2argv-execs' 'libpcap' 'openssl')
+makedepends=('python' 's2argv-execs' 'libpcap' 'openssl')
+provides=("$_pkgname" "$_pkgname2")
+conflicts=("$_pkgname" "$_pkgname2")
+replaces=("$_pkgname2")
+source=(
+ "git+$url.git"
+ "git+https://github.com/virtualsquare/vde-2.git"
+ dhcpd.conf.sample
+ iptables.rules.sample
+ vde-config.sample
+ vde-connection.sample
+)
+install=vde2.install
+sha256sums=(
+ 'SKIP'
+ 'SKIP'
+ 'da0e2766dc63069da929c28126831ad5fdddcc4a04105a21217d78832c7ca1bc'
+ '99076d7466cd99673dbe91ef83865187e7868177959b38e125df63eea957f83e'
+ '5727c215646333c37b26388146cd3e6b3814b88d60d54051d7da99e00c0aef87'
+ '5139110ed6d5d1174bf12971512dac5196d9d07df46dd393d7b1cd083118fe9b'
+)
pkgver() {
cd "$_pkgname"
@@ -24,13 +42,29 @@ pkgver() {
}
build() {
- cd "$_pkgname"
+ cd "vde-2"
+ autoreconf -if
+ libtoolize
+ autoreconf -if
+ ./configure --prefix=/usr --sbindir=/usr/bin --sysconfdir=/etc --libexecdir=/usr/lib/vde2 --enable-experimental
+ make
+
+ cd "../$_pkgname"
autoreconf -i
./configure --prefix="/usr"
make
}
package() {
- cd "$_pkgname"
+ cd "vde-2"
+ make prefix="$pkgdir"/usr sysconfdir="$pkgdir"/etc sbindir="$pkgdir"/usr/bin libexecdir="$pkgdir"/usr/lib/vde2 install
+ install -D -m 644 ../vde-config.sample $pkgdir/etc/vde/vde-config.sample
+ install -D -m 644 ../vde-connection.sample $pkgdir/etc/vde/vde-connection.sample
+ install -D -m 644 ../dhcpd.conf.sample $pkgdir/usr/share/vde2/dhcpd.conf.sample
+ install -D -m 644 ../iptables.rules.sample $pkgdir/usr/share/vde2/iptables.rules.sample
+ # install slirp license
+ install -D -m 644 COPYING.slirpvde $pkgdir/usr/share/licenses/vde2/COPYING.slirpvde
+
+ cd "../$_pkgname"
make DESTDIR="$pkgdir/" install
}
diff --git a/dhcpd.conf.sample b/dhcpd.conf.sample
new file mode 100644
index 000000000000..565a78b27c94
--- /dev/null
+++ b/dhcpd.conf.sample
@@ -0,0 +1,12 @@
+ddns-update-style none;
+
+subnet 192.168.254.0 netmask 255.255.255.0 {
+ range 192.168.254.1 192.168.254.253;
+ option routers 192.168.254.254;
+ option domain-name "virtual.example.com";
+ # find your DNS servers from /etc/resolv.conf
+ # otherwise only pure IP addresses will work
+ option domain-name-servers 192.168.254.254;
+ option broadcast-address 192.168.254.255;
+ default-lease-time 86400;
+}
diff --git a/iptables.rules.sample b/iptables.rules.sample
new file mode 100644
index 000000000000..ac712ee21b4e
--- /dev/null
+++ b/iptables.rules.sample
@@ -0,0 +1,5 @@
+*filter
+-A INPUT -i tun -j ACCEPT
+-A FORWARD -s 192.168.254.0/255.255.255.0 -j ACCEPT
+*nat
+-A POSTROUTING -s 192.168.254.0/24 -j MASQUERADE
diff --git a/vde-config.sample b/vde-config.sample
new file mode 100644
index 000000000000..f7e0660a40fa
--- /dev/null
+++ b/vde-config.sample
@@ -0,0 +1,35 @@
+# Set options vde_switch program
+# To activate this vde profile add it to /etc/conf.d/vde
+
+# Global options
+VDE_NUMPORTS="32" # Number of ports (default 32)
+VDE_HUB="no" # [yes|no] Make the switch act as a hub
+VDE_FSTP="no" # [yes|no] Activate the fast spanning tree protocol
+VDE_MAC="" # Set the Switch MAC address
+VDE_PRIORITY="" # Set the priority for FST (MAC extension)
+VDE_HASHSIZE="" # Hash table size
+
+# Options from datasock module
+VDE_SOCK="/var/run/vde/sample.sock" # control directory pathname
+VDE_SOCK_MODE="660" # Standard access mode for comm sockets (octal)
+VDE_SOCK_GROUP="root" # Group owner for comm sockets
+
+# Options from consmgmt module
+VDE_MANAGEMENT_SOCK="/var/run/vde/sample.mgmt" # path of the management UNIX socket
+VDE_MANAGEMENT_SOCK_MODE="660" # management UNIX socket access mode (octal)
+
+# Other options to parse to vde_switch
+VDE_OPTIONS=""
+
+# VDE with internet support
+# You can use either tuntap method or slirpvde method.
+
+# Options from tuntap module
+VDE_TAP="" # Enable routing through TAP tap interface (comma separated array eg.:"tap0,tap1").
+
+# slirpvde daemon support
+SLIRP="no" # [yes|no] enable/disable SLIRP daemon support
+SLIRP_DHCP="no" # [yes|no] turn on the DHCP server for the network autoconfiguration of all the units connected to the VDE
+SLIRP_NETWORK="" # specify the network address (default 10.0.2.0)
+# other options to parse to slirpvde
+SLIRP_OPTIONS=""
diff --git a/vde-connection.sample b/vde-connection.sample
new file mode 100644
index 000000000000..4a75e1f52aa2
--- /dev/null
+++ b/vde-connection.sample
@@ -0,0 +1,6 @@
+# You can add vde switch connections below
+# just without the # at the beginning:
+# vde_plug /var/run/vde/sample.sock = vde_plug /var/run/vde/sample2.sock
+# or if hosts are different use this syntax:
+# vde_plug /var/run/vde/sample.sock = ssh host2 vde_plug /var/run/vde/sample.sock
+
diff --git a/vde2.install b/vde2.install
new file mode 100644
index 000000000000..bf538e01f234
--- /dev/null
+++ b/vde2.install
@@ -0,0 +1,9 @@
+post_install() {
+ echo "vde config files should be placed in /etc/vde, sample files are provided."
+ echo "iptables and dhcpd sample files have been installed to '/usr/share/vde2'."
+ echo "Merge those examples, if needed to the according config files."
+}
+
+post_upgrade() {
+ post_install $1
+}