diff --git a/package/gluon-config-mode-mesh-vpn/Makefile b/package/gluon-config-mode-mesh-vpn/Makefile index c52ffed1d3430818e10f2fda81e6e1621fc9fb13..20e5c0164c0bdf65a6e6421b3586777104a8d61f 100644 --- a/package/gluon-config-mode-mesh-vpn/Makefile +++ b/package/gluon-config-mode-mesh-vpn/Makefile @@ -14,7 +14,7 @@ define Package/gluon-config-mode-mesh-vpn SECTION:=gluon CATEGORY:=Gluon TITLE:=Toggle mesh-vpn and bandwidth limit - DEPENDS:=gluon-config-mode-core-virtual +gluon-mesh-vpn-fastd + DEPENDS:=gluon-config-mode-core-virtual +gluon-mesh-vpn-core endef define Build/Prepare diff --git a/package/gluon-config-mode-mesh-vpn/i18n/de.po b/package/gluon-config-mode-mesh-vpn/i18n/de.po index 8c613aa0c04c522b27fe51de511f13de56146de2..06d44b8c4fd6e9a6977475327b34739ed0fb1701 100644 --- a/package/gluon-config-mode-mesh-vpn/i18n/de.po +++ b/package/gluon-config-mode-mesh-vpn/i18n/de.po @@ -1,8 +1,8 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"PO-Revision-Date: 2015-03-19 22:05+0100\n" -"Last-Translator: Matthias Schiffer <mschiffer@universe-factory.net>\n" +"PO-Revision-Date: 2015-10-07 00:32+0100\n" +"Last-Translator: Cyrus Fox <cyrus@lambdacore.de>\n" "Language-Team: German\n" "Language: de\n" "MIME-Version: 1.0\n" @@ -23,14 +23,14 @@ msgid "Use internet connection (mesh VPN)" msgstr "Internetverbindung nutzen (Mesh-VPN)" msgid "" -"Your internet connection can be used to establish an encrypted connection " +"Your internet connection can be used to establish a VPN connection " "with other nodes. Enable this option if there are no other nodes reachable " "over WLAN in your vicinity or you want to make a part of your connection's " "bandwidth available for the network. You can limit how much bandwidth the " "node will use at most." msgstr "" "Dein Knoten kann deine Internetverbindung nutzen um darüber eine " -"verschlüsselte Verbindung zu anderen Knoten aufzubauen. Die dafür " +"VPN-Verbindung zu anderen Knoten aufzubauen. Die dafür " "genutzte Bandbreite kannst du beschränken. Aktiviere die Option, falls keine " "per WLAN erreichbaren Nachbarknoten in deiner Nähe sind oder du deine " "Internetverbindung für das Mesh-Netzwerk zur Verfügung stellen möchtest." diff --git a/package/gluon-config-mode-mesh-vpn/i18n/fr.po b/package/gluon-config-mode-mesh-vpn/i18n/fr.po index fc85461323f5310a0b5af6cdfdf54694c801771f..0c324f326d0dc066767ac73fa0bd46eabe5cbb69 100644 --- a/package/gluon-config-mode-mesh-vpn/i18n/fr.po +++ b/package/gluon-config-mode-mesh-vpn/i18n/fr.po @@ -1,12 +1,12 @@ msgid "" msgstr "" -"Content-Type: text/plain; charset=UTF-8\n" "Project-Id-Version: PACKAGE VERSION\n" "PO-Revision-Date: 2015-08-12 23:30+0100\n" "Last-Translator:Tobias Bernot <tqbs@airmail.cc>\n" "Language-Team: French\n" "Language: fr\n" "MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" @@ -23,14 +23,9 @@ msgid "Use internet connection (mesh VPN)" msgstr "Utiliser la connection internet (Mesh-VPN)" msgid "" -"Your internet connection can be used to establish an encrypted connection " -"with other nodes. Enable this option if there are no other nodes reachable " -"over WLAN in your vicinity or you want to make a part of your connection's " +"Your internet connection can be used to establish a VPN connection with " +"other nodes. Enable this option if there are no other nodes reachable over " +"WLAN in your vicinity or you want to make a part of your connection's " "bandwidth available for the network. You can limit how much bandwidth the " "node will use at most." msgstr "" -"Votre nœud peut partager votre accès internet grâce une communication encryptée " -"avec d'autres nœuds. Vous pouvez limiter la bande passante utilisée par ceci. " -"Active cette option, si vous n'avez pas d'autres nœuds atteignables par WLAN " -"ou si vous voulez partager votre bande passante pour le réseau MESH." - diff --git a/package/gluon-config-mode-mesh-vpn/i18n/gluon-config-mode-mesh-vpn.pot b/package/gluon-config-mode-mesh-vpn/i18n/gluon-config-mode-mesh-vpn.pot index 52e2eef8acebab13800df56ff7f487b3647733b4..b6722919971f1a32da03ed79c92d7172620d1fb7 100644 --- a/package/gluon-config-mode-mesh-vpn/i18n/gluon-config-mode-mesh-vpn.pot +++ b/package/gluon-config-mode-mesh-vpn/i18n/gluon-config-mode-mesh-vpn.pot @@ -14,7 +14,7 @@ msgid "Use internet connection (mesh VPN)" msgstr "" msgid "" -"Your internet connection can be used to establish an encrypted connection " +"Your internet connection can be used to establish a VPN connection " "with other nodes. Enable this option if there are no other nodes reachable " "over WLAN in your vicinity or you want to make a part of your connection's " "bandwidth available for the network. You can limit how much bandwidth the " diff --git a/package/gluon-config-mode-mesh-vpn/luasrc/lib/gluon/config-mode/wizard/0300-mesh-vpn.lua b/package/gluon-config-mode-mesh-vpn/luasrc/lib/gluon/config-mode/wizard/0300-mesh-vpn.lua index 6aa4ee52ae6c84ba534bc6122eb2e16698e0fd9c..69a64bd065eb6cfe355c2fde7e57a53027092e48 100644 --- a/package/gluon-config-mode-mesh-vpn/luasrc/lib/gluon/config-mode/wizard/0300-mesh-vpn.lua +++ b/package/gluon-config-mode-mesh-vpn/luasrc/lib/gluon/config-mode/wizard/0300-mesh-vpn.lua @@ -1,7 +1,16 @@ +local fs = require "nixio.fs" + +local has_fastd = fs.access('/lib/gluon/mesh-vpn/fastd') +local has_tunneldigger = fs.access('/lib/gluon/mesh-vpn/tunneldigger') + return function(form, uci) + if not (has_fastd or has_tunneldigger) then + return + end + local msg = translate( - 'Your internet connection can be used to establish an ' .. - 'encrypted connection with other nodes. ' .. + 'Your internet connection can be used to establish a ' .. + 'VPN connection with other nodes. ' .. 'Enable this option if there are no other nodes reachable ' .. 'over WLAN in your vicinity or you want to make a part of ' .. 'your connection\'s bandwidth available for the network. You can limit how ' .. @@ -13,9 +22,14 @@ return function(form, uci) local o local meshvpn = s:option(Flag, "meshvpn", translate("Use internet connection (mesh VPN)")) - meshvpn.default = uci:get_bool("fastd", "mesh_vpn", "enabled") + meshvpn.default = uci:get_bool("fastd", "mesh_vpn", "enabled") or uci:get_bool("tunneldigger", "mesh_vpn", "enabled") function meshvpn:write(data) - uci:set("fastd", "mesh_vpn", "enabled", data) + if has_fastd then + uci:set("fastd", "mesh_vpn", "enabled", data) + end + if has_tunneldigger then + uci:set("tunneldigger", "mesh_vpn", "enabled", data) + end end local limit = s:option(Flag, "limit_enabled", translate("Limit bandwidth")) @@ -43,5 +57,5 @@ return function(form, uci) uci:set("simple-tc", "mesh_vpn", "limit_egress", data) end - return {'fastd', 'simple-tc'} + return {'fastd', 'tunneldigger', 'simple-tc'} end