mirror of
https://github.com/kasmtech/KasmVNC.git
synced 2024-11-24 00:53:39 +01:00
vncserver: fix -websocketPort being ignored
This commit is contained in:
parent
f3681c87f9
commit
7cced9dd05
@ -1117,7 +1117,7 @@ sub DefineFilePathsAndStuff {
|
|||||||
}
|
}
|
||||||
|
|
||||||
sub ParseAndProcessCliOptions {
|
sub ParseAndProcessCliOptions {
|
||||||
my @supportedOptions = ("-geometry",1,"-depth",1,"-pixelformat",1,"-name",1,"-kill",1,"-help",0,"-h",0,"--help",0,"-fp",1,"-list",0,"-fg",0,"-autokill",0,"-noxstartup",0,"-xstartup",1,"-select-de",OPTIONAL_ARG_VALUE, "-interface", REQUIRED_ARG_VALUE, '-debug', NO_ARG_VALUE);
|
my @supportedOptions = ("-geometry",1,"-depth",1,"-pixelformat",1,"-name",1,"-kill",1,"-help",0,"-h",0,"--help",0,"-fp",1,"-list",0,"-fg",0,"-autokill",0,"-noxstartup",0,"-xstartup",1,"-select-de",OPTIONAL_ARG_VALUE, "-interface", REQUIRED_ARG_VALUE, '-debug', NO_ARG_VALUE, '-websocketPort', REQUIRED_ARG_VALUE);
|
||||||
ParseOptionsAndRemoveMatchesFromARGV(@supportedOptions);
|
ParseOptionsAndRemoveMatchesFromARGV(@supportedOptions);
|
||||||
ProcessCliOptions();
|
ProcessCliOptions();
|
||||||
CheckGeometryAndDepthAreSensible();
|
CheckGeometryAndDepthAreSensible();
|
||||||
@ -1140,7 +1140,8 @@ sub PrepareDefaultsForPassingToXvnc {
|
|||||||
%default_opts;
|
%default_opts;
|
||||||
%config;
|
%config;
|
||||||
|
|
||||||
$websocketPort = $defaultWebsocketPort + $displayNumber;
|
$websocketPort = $opt{"-websocketPort"} || \
|
||||||
|
GenerateWebsocketPortFromDisplayNumber();
|
||||||
$desktopName = $opt{'-name'} || "$host:$displayNumber ($ENV{USER})";
|
$desktopName = $opt{'-name'} || "$host:$displayNumber ($ENV{USER})";
|
||||||
|
|
||||||
SetReasonabeDefaults();
|
SetReasonabeDefaults();
|
||||||
@ -1148,6 +1149,10 @@ sub PrepareDefaultsForPassingToXvnc {
|
|||||||
CheckBrowserHostDefined();
|
CheckBrowserHostDefined();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub GenerateWebsocketPortFromDisplayNumber {
|
||||||
|
$defaultWebsocketPort + $displayNumber;
|
||||||
|
}
|
||||||
|
|
||||||
sub EnsureAtLeastOneKasmUserExists {
|
sub EnsureAtLeastOneKasmUserExists {
|
||||||
@kasmPasswdUsers = LoadKasmPasswdUsers();
|
@kasmPasswdUsers = LoadKasmPasswdUsers();
|
||||||
if (!AtLeastOneUserConfigured()) {
|
if (!AtLeastOneUserConfigured()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user