From bb28d26191a1fee71efcdadcd48182272fb8f3ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C4=81nis=20Jansons?= Date: Tue, 22 Aug 2023 13:13:33 +0300 Subject: [PATCH] Updated docs --- README.md | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index b9e22d6..4c0c8b2 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@ On Linux secrets will be shortly stored in tmpfs (memory) and deleted once they After setting up, change the run-vpn.sh, routing.sh and hostscan-bypass.sh ownership to root: -``` +```sh chown root:root run-vpn.sh chown root:root hostscan-bypass.sh chown root:root routing.sh @@ -54,19 +54,26 @@ Rename routes.txt.sample to routes.txt or create an empty routes.txt and add sub ## Usage ### Usage from terminal -``` +```sh DBUS_SESSION_BUS_ADDRESS=$DBUS_SESSION_BUS_ADDRESS sudo -E ./run-vpn.sh ``` You can stop it by pressing `CTRL+C` or killing the process. ### GUI usage from bitbar/xbar/swaybar/argos -Consult the `bitbar-openconnect` script for sudoers entries needed to run it. Add them to `/etc/sudoers` +Consult the `bitbar-openconnect.6s.sh` script for sudoers entries needed to run it. Add them to `/etc/sudoers` -**Symlink**(!) the `bitbar-openconnect` script to your bitbar config folder: +**Symlink**(!) the `bitbar-openconnect.6s.sh` script to your bitbar config folder: +```sh +ln -s ~/Documents/git/always-on-openconnect-vpn/bitbar-openconnect.6s.sh ~/.config/argos/ ``` -ln -s ~/Documents/git/always-on-openconnect-vpn.6s.sh ~/.config/argos/ + +Enable running from your `user`, add this to /etc/sudoers: + +```sh +user ALL=(ALL) NOPASSWD:SETENV: /home/user/Documents/git/always-on-openconnect-vpn/run-vpn.sh +user ALL=(ALL) NOPASSWD: /usr/bin/killall -2 openconnect ``` ### Yubikey