Apply display settings on RDP connections opened from .RDP files?
Hi all,
In RDM, you can configure templates for RDP sessions. Any new RDP entry you create in RDM will be able to use the template and this saves you time from having to configure specific settings over and over again. The problem is that this only works for entries that you create in RDM. I'm trying to figure out how to apply this template to .RDP files that I open with RDM.
We use the Bastion native connect method to connect to our Azure VMs with our AAD credentials. For those unfamiliar, Bastion native connect is an AZ CLI extension and you basically run some command in Powershell. In the background, AZ CLI will download a temporary .rdp file under %temp% and then open it up with MSTSC to connect. I've figured out a way to use a script to intercept this .rdp file and modify a few settings inside the .rdp file, then open it up with RDM instead of MSTSC. It works great, the only problem is that it doesn't apply the RDP-specific display settings such as smart-sizing, because this is obviously unique to RDM and can't be added to the .rdp file itself.
My question is, for any .rdp file that we open with RDM, is there a way to force RDM specific settings onto it? I don't want to always have to save a RDP entry into RDM. Sometimes, opening a .rdp file with RDM is just a temporary session.
--------------------------------------------------------------------------------------------------------------------
I'm always using the latest beta RDM x64 version.
Local data source.
Hi chaoscreator
There might be a way to achieve what you're asking (I'll have to let a member of the support or RDM Windows team give you an answer), but I'm wondering if this is an x-y problem.
Is there a reason you don't use the native Azure Bastion integration built in to RDM? You can create an Azure Bastion VPN type, then configure it as the VPN on an RDP entry which gives you the full breadth of options available (and saves you from manually using `az` to grab the .rdp file for a host).
Let me know if something isn't clear or you have any questions
Kind regards,
Richard Markievicz
Didn't know about that, I'll try it out.
--------------------------------------------------------------------------------------------------------------------
I'm always using the latest beta RDM x64 version.
Local data source.
Hello again
If you're mainly working with temporary connections that you don't want to create an entry for, then it might not be a final solution. But please take a look at that and let us know how you get on; it's possible your requirements are already met (or could easily be met) by RDM.
Thanks and kind regards,
Richard Markievicz
I followed the guide here:
I'm getting this error:

I'm not sure what that means. I think it's saying it can't find the Bastion resource. I've let it prompt me for auth and I'm definitely auth to my Azure tenant properly. Also tried to use AZ CLI and Powershell login as prompt options. For the host, I'm not sure what to put there. In your guide, the example is "Devolutions-202309011056-vnet-bastion", but I don't know how this was derived.
The other issue is that my Bastion is located under the Connectivity subscription, while my VMs are located in another subscription. Not sure if RDM will support using Bastion from a different sub and then connect to the VM that belongs to another sub. And what about situations where you have the same VM name found in different subs? How does it know which one to connect? Normally, you'd specify the resource ID of the resource.
Also, while I do want to get the Bastion setup working, I still think it's worthwhile for your team to look at my original issue. There may be situations where I just download a .rdp file and it doesn't have to do with Azure or Bastion at all. I may just want to open the .rdp file with RDM and have some of my default RDM settings applied automatically, without having to save the RDP entry.
--------------------------------------------------------------------------------------------------------------------
I'm always using the latest beta RDM x64 version.
Local data source.