mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2026-11-19 06:26:14 -05:00
refactor: authenticate service websocket transport
This commit is contained in:
31 files changed
+3304
-441
No files matched your search
Executable
+25
@@ -0,0 +1,25 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
repo=$(CDPATH= cd "$(dirname "$0")/.." && pwd)
|
||||
cd "$repo"
|
||||
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
echo "Run this script as the desktop user; it invokes sudo only for gpservice." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
uid=$(id -u)
|
||||
if [ -n "${GP_DEV_BOOTSTRAP_SOCKET:-}" ]; then
|
||||
socket=$GP_DEV_BOOTSTRAP_SOCKET
|
||||
else
|
||||
socket=/var/run/gpservice-dev-$uid/dev-bootstrap.sock
|
||||
fi
|
||||
|
||||
cargo build -p gpservice
|
||||
echo "Debug credential socket: $socket"
|
||||
exec sudo target/debug/gpservice \
|
||||
--dev-standalone \
|
||||
--dev-uid "$uid" \
|
||||
--dev-bootstrap-socket "$socket" \
|
||||
"$@"
|
||||
Reference in new issue
Block a user