summaryrefslogtreecommitdiffstats
path: root/remote/modules/vmchooser2/data/opt/openslx/vmchooser/sessionstart.d/log-selected-session
blob: fb8ae9eb6091551dab35f2b2c79960b67c0bf69b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/ash

[ -z "${SESSION_UUID}${SESSION_NAME}" ] && exit 0

. /opt/openslx/config

[ -z "$SLX_REMOTE_LOG" ] && exit 0

REALUSER=$(whoami)
LOGUSER=0
[ "x$SLX_REMOTE_LOG_SESSIONS" = "xyes" ] && LOGUSER=1

curl --data-urlencode "type=.vmchooser-session" --data-urlencode "uuid=$SESSION_UUID" --data-urlencode "name=$SESSION_NAME" \
		--data-urlencode "user=$REALUSER" --data-urlencode "loguser=$LOGUSER" "$SLX_REMOTE_LOG"

exit 0