Remove another command string
This commit is contained in:
19
installJRMC
19
installJRMC
@@ -1293,7 +1293,7 @@ service_jriver-xvnc() {
|
|||||||
systemctl_reload_cmd
|
systemctl_reload_cmd
|
||||||
if ! systemctl_enable_cmd "$SERVICE_NAME"; then
|
if ! systemctl_enable_cmd "$SERVICE_NAME"; then
|
||||||
err "vncserver failed to start on DISPLAY $NEXT_DISPLAY"
|
err "vncserver failed to start on DISPLAY $NEXT_DISPLAY"
|
||||||
err "Incrementing DISPLAY by one and retrying"
|
err "Incrementing DISPLAY and retrying"
|
||||||
service_jriver-xvnc increment
|
service_jriver-xvnc increment
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
@@ -1312,7 +1312,7 @@ service_jriver-x11vnc() {
|
|||||||
setServiceVars "${FUNCNAME[0]##*_}"
|
setServiceVars "${FUNCNAME[0]##*_}"
|
||||||
setDisplay
|
setDisplay
|
||||||
|
|
||||||
declare start_cmd
|
declare -a start_cmd
|
||||||
declare -g PORT=$(( DISPLAYNUM + 5900 ))
|
declare -g PORT=$(( DISPLAYNUM + 5900 ))
|
||||||
|
|
||||||
installPackage x11vnc
|
installPackage x11vnc
|
||||||
@@ -1327,10 +1327,19 @@ service_jriver-x11vnc() {
|
|||||||
xauth add "$HOST$DISPLAY" . "$(xxd -l 16 -p /dev/urandom)"
|
xauth add "$HOST$DISPLAY" . "$(xxd -l 16 -p /dev/urandom)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
start_cmd=(
|
||||||
|
/usr/bin/x11vnc
|
||||||
|
-display "$DISPLAY"
|
||||||
|
-noscr
|
||||||
|
-auth guess
|
||||||
|
-forever
|
||||||
|
-bg
|
||||||
|
)
|
||||||
|
|
||||||
if (( NOVNCAUTH )); then
|
if (( NOVNCAUTH )); then
|
||||||
start_cmd="/usr/bin/x11vnc -display $DISPLAY -noscr -auth guess -forever -bg -nopw"
|
start_cmd+=(-nopw)
|
||||||
else
|
else
|
||||||
start_cmd="/usr/bin/x11vnc -display $DISPLAY -noscr -auth guess -forever -bg -rfbauth $HOME/.vnc/jrmc_passwd"
|
start_cmd+=(-rfbauth "$HOME/.vnc/jrmc_passwd")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo bash -c "cat <<-EOF > $SERVICE_FNAME
|
sudo bash -c "cat <<-EOF > $SERVICE_FNAME
|
||||||
@@ -1342,7 +1351,7 @@ service_jriver-x11vnc() {
|
|||||||
$USER_STRING
|
$USER_STRING
|
||||||
Type=forking
|
Type=forking
|
||||||
Environment=DISPLAY=$DISPLAY
|
Environment=DISPLAY=$DISPLAY
|
||||||
ExecStart=$start_cmd
|
ExecStart=${start_cmd[*]}
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=10
|
RestartSec=10
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user