I have done this a number of times before with no issue but today setup a new server and getting the following error each time I try to deploy to RD Gateway
Using the 7.0.17 version
Deploy to RDP Gateway Service :: Module RemoteDesktopServices is loaded in Windows PowerShell using WinPSCompatSession remoting session; please note that all input and output of commands from this module will be deserialized objects. If you want to load this module into PowerShell please use ‘Import-Module -SkipEditionCheck’ syntax. Error: Cannot find drive. A drive with the name ‘RDS’ does not exist. at , : line 12
Thanks, support question for licensed customers should be directed to support at certifytheweb.com
v7 is pretty different to v6, in particular it uses .net 10 and the corresponding PowerShell SDK so I suspect we are seeing the difference due to that.
I’m not an RD Gateway admin so don’t know the various components but I was able to reproduce the same error you were seeing on a new install.
I don’t know if that’s specific to v7 of the app or if it’s because I’m testing on Server 2025, but as an alternative here is an example script that seems to have worked for me:
param($result)
Import-Module RemoteDesktopServices
# Apply certificate to RD Roles
Set-RDCertificate -Role RDGateway -Thumbprint $result.ManagedItem.CertificateThumbprintHash
# optional service restarts
# Restart-Service IAS -Force -ErrorAction Stop
# Restart-Service TSGateway -Force -ErrorAction Stop
# Restart-Service SSTPSvc -Force -ErrorAction Stop
# Write-Host "Services Restarted."
You can obviously adapt the script to whatever you want.
- Add a Run Powershell Script deployment task
- Under Task Parameters point Program/Script to the script file and check “Launch New Process”. I tried it without the new process check and it failed on some temporary file PSRemote proxy thing. It may work for you without that as your RD system is probably properly configured compared to mine.
- Then save and try running the task (you don’t have to re-request your certificate).
For comparison, here is our standard script used by the Deploy to RDP Gateway Service task: certify-plugins/src/DeploymentTasks/Core/Providers/Assets/RDPGatewayServices.ps1 at development · webprofusion/certify-plugins · GitHub
Thanks. Ill have to try it in a couple of days as hit limit of certificate requests
Solved for the moment by manually selecting the certificate in RD gateway manager
Yeah if your managed certificate already has a certificate (which it likely will) you just click the Play button next to the task itself, you don’t have to click Request Certificate.