Able to have pass in vnc
This commit is contained in:
parent
ea5661fa41
commit
7ad2eb45c8
|
@ -1,3 +1,8 @@
|
|||
VNC pass
|
||||
--------
|
||||
|
||||
Passing ```VNC_PASSWORD="your_pass_here"``` will secure your vnc connection.
|
||||
|
||||
Proxy
|
||||
-----
|
||||
|
||||
|
|
13
src/vnc.sh
Executable file
13
src/vnc.sh
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/bash
|
||||
|
||||
vnc="/usr/bin/x11vnc -display ${DISPLAY} -forever -shared "
|
||||
|
||||
pass_path="/root/vncpass"
|
||||
if [ ! -z "${VNC_PASSWORD}" ]; then
|
||||
/usr/bin/x11vnc -storepasswd ${VNC_PASSWORD} ${pass_path}
|
||||
param="-rfbauth ${pass_path}"
|
||||
else
|
||||
param="-nopw"
|
||||
fi
|
||||
|
||||
${vnc}${param}
|
|
@ -17,7 +17,7 @@ stderr_logfile=%(ENV_LOG_PATH)s/openbox.stderr.log
|
|||
priority=2
|
||||
|
||||
[program:x11vnc]
|
||||
command=/usr/bin/x11vnc -display %(ENV_DISPLAY)s -nopw -forever -shared
|
||||
command=./src/vnc.sh
|
||||
stdout_logfile=%(ENV_LOG_PATH)s/x11vnc.stdout.log
|
||||
stderr_logfile=%(ENV_LOG_PATH)s/x11vnc.stderr.log
|
||||
priority=2
|
||||
|
|
Loading…
Reference in a new issue