From mboxrd@z Thu Jan 1 00:00:00 1970 From: "pelzflorian (Florian Pelz)" Subject: Getting network-manager-openconnect to work Date: Tue, 10 Sep 2019 13:21:20 +0200 Message-ID: <20190910112120.ezqnrrfffhhjvc2d@pelzflorian.localdomain> References: <87sgp4pj7s.fsf@santanas.co.za> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="yxll7soljvp62x7j" Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:43960) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i7eDF-00035T-Gf for help-guix@gnu.org; Tue, 10 Sep 2019 07:21:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i7eDB-0005in-R9 for help-guix@gnu.org; Tue, 10 Sep 2019 07:21:33 -0400 Content-Disposition: inline In-Reply-To: <87sgp4pj7s.fsf@santanas.co.za> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: Divan Santana Cc: bug-guix@gnu.org, Help guix --yxll7soljvp62x7j Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 10, 2019 at 11:57:11AM +0200, Divan Santana wrote: > Hi Guix, >=20 > I'm glad openconnect and network-manager-openconnect are now in Guix! >=20 > It would be nice to get it to work via network-manager, though I suppos= e > it's not essential. >=20 > Using openconnect directly works for me. >=20 > $ sudo openconnect vpn.somewhere.com >=20 > Trying to get it work via network-manager gives an error like so: >=20 > $ sudo nmcli con up vpn-fnb --ask > Error: openconnect failed: Could not find "openconnect" binary > A password is required to connect to 'vpn-fnb'. > Gateway (vpn.secrets.gateway): >=20 > Even though my services configuration has this vpn-plugins set. >=20 > (modify-services %desktop-services > (network-manager-service-type > config =3D> (network-manager-configuration > (inherit config) > (dns "dnsmasq") > (vpn-plugins (list network-manager-opencon= nect)) > )) >=20 > Anyone else seen this? Cc=E2=80=99ing bug-guix@gnu.org I suspect something like the attached patch would help (and expand the closure of network-manager to always include openconnect). To test, follow section =E2=80=9CBuilding from Git=E2=80=9D from the manu= al or Laura=E2=80=99s video 04-packaging-part-one.webm from , but after the initial clone command, do git apply the-attached.patch Then after make, do sudo -E ./pre-inst-env guix system reconfigure /etc/config.scm (or whatever your configuration file is called). I cannot test right now and have never used openconnect. It is quite possible I made a mistake. Regards, Florian --yxll7soljvp62x7j Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0001-gnu-network-manager-Enable-openconnect-helper.patch" >From 8de7675a2dc2c1385d312e35136f8fa9eb4f9825 Mon Sep 17 00:00:00 2001 From: Florian Pelz Date: Tue, 10 Sep 2019 12:59:19 +0200 Subject: [PATCH] gnu: network-manager: Enable openconnect helper. * gnu/packages/gnome.scm (network-manager): Add openconnect input. Patch source to use it instead of searching /usr/bin. --- gnu/packages/gnome.scm | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index efe5206e53..a6ea09d8f6 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -5372,6 +5372,13 @@ users.") (("src/devices/tests/test-lldp") " ") (("src/tests/test-route-manager-linux") " ")) #t)) + (add-after 'unpack 'patch-source + (lambda* (#:key inputs #:allow-other-keys) + (begin + (substitute* "clients/common/nm-vpn-helpers.c" + (("\\\"/usr/sbin/openconnect\\\"") + (string-append openconnect "\"/bin/openconnect\""))) + #t))) (add-after 'unpack 'delete-failing-tests (lambda _ ;; FIXME: These four tests fail for unknown reasons. @@ -5434,6 +5441,7 @@ users.") ("libsoup" ,libsoup) ("modem-manager" ,modem-manager) ("newt" ,newt) ;for the 'nmtui' console interface + ("openconnect" ,openconnect) ("polkit" ,polkit) ("ppp" ,ppp) ("readline" ,readline) -- 2.23.0 --yxll7soljvp62x7j--