-
Hi, I have tried the whole afternoon to find a way, but I am out of ideas now. I serve through Xrdp/Xvnc an application which is started through a script. That script is configured in sesman.ini as the "DefaultWindowManager". This works great. What I would like to achieve is depending on the menu chosen in the Xrdp Greeter (called Session), start a different application. So if I choose the first menu item, it would call one "DefaultWindowManager" and if I choose the second menu item, it would call another "DefaultWindowManager". Any way to do this (I am running RHEL8)? Thanks |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments 1 reply
-
as far as I know you there is no information around what the user selected when startwm is called. I think you knew that already, but rdp has a "shell" parameter with mstsc you can pass that parameter by creating a .rdp file and appending ex.
with freerdp the parameter is then instead of startwm.sh this command is executed |
Beta Was this translation helpful? Give feedback.
-
thanks for your suggestion, it would be an option even if I would have to deploy then that rdp file to clients. Better than nothing! I tried the option "[SessionVariables]" which I can see from from my script but it doesn't tell me which Session was selected. I will have to look in the code may be. |
Beta Was this translation helpful? Give feedback.
-
It's pretty straightforward to pass the session type through to the session startup script as an environment variable, and it would certainly help this use-case. Are you in a position to build from source, @vongillus ? |
Beta Was this translation helpful? Give feedback.
-
Well I can for sure build from source since I would deploy this specific XRDP version only on a bunch of servers, but for this I would need a patch. And that's where I am completely out of my field. So if you have any idea, I would really appreciate! :) |
Beta Was this translation helpful? Give feedback.
-
Thanks. What version of xrdp are you planning on deploying? We can patch against that. |
Beta Was this translation helpful? Give feedback.
-
I am planning to recompile the one which I use from EPEL, which is https://download.fedoraproject.org/pub/epel/8/Everything/SRPMS/x/xrdp-0.9.21-1.el8.src.rpm |
Beta Was this translation helpful? Give feedback.
-
Hi @vongillus I've just had a more detailed look at this, and I must apologise for leading you on. It's way more complicated to do this for v0.9.x because the middleware for that version is rather difficult to modify without lots of testing. We replaced it completely in the devel version, and that's what I was thinking of when I replied to you (rather too hastily it seems). The implementation of this feature needs the session type string to be passed from xrdp to xrdp-sesman. I'll certainly mark this as a feature request for the next major release. In the meantime, I think @akarl10's suggestion is probably the way to go, as a patch from me would be rather complex and not tested to the same degree as the vanilla code from EPEL. |
Beta Was this translation helpful? Give feedback.
as far as I know you there is no information around what the user selected when startwm is called.
I agree that it would be cool if the desktop environment could be selected here.
I think you knew that already, but rdp has a "shell" parameter
with mstsc you can pass that parameter by creating a .rdp file and appending ex.
with freerdp the parameter is
/shell:/etc/xrdp/my-custom-shell.sh
then instead of startwm.sh this command is executed