Previously, we explained how to publish RemoteApp programs on your RDS infrastructure through the server manager.
Nevertheless, for those who would like to automate the installation of RemoteApp programs and their publications, here is how to do it via the command line (cmd + powershell).
To install RemoteApp programs on a session host server, you must first switch your server to "installation" mode.
Indeed, by default, the server is in "Execute" mode.
To check it, just use this command :
Batch
change user /query
Plain Text
User session is ready to execute applications.
Then, to switch your server to "Install" mode, type this command :
Batch
change user /install
Plain Text
User session is ready to install applications.
Now, you can install whatever you want from this command prompt or through the GUI.
Once you're done, you'll be able to switch your server back to Execute mode.
Batch
change user /execute
Plain Text
User session is ready to execute applications.
Finally, to publish your RemoteApp programs, create the necessary collection (s) through the GUI, and open a PowerShell command prompt.
In this PowerShell prompt, first import the "RemoteDesktop" module.
PowerShell
Import-Module RemoteDesktop
Then, rely on this powershell command to publish them :
PowerShell
New-RDRemoteApp -Alias [the program name without space] -DisplayName "[display name]" -FilePath "[full path of the file to launch]" -ShowInWebAccess 1 -CollectionName [collection name] -ConnectionBroker [broker server FQDN]
Which gives in our case :
PowerShell
New-RDRemoteApp -Alias EXCEL -DisplayName "Excel 2013" -FilePath "C:\Program Files\Microsoft Office\Office15\EXCEL.exe" -ShowInWebAccess 1 -CollectionName Office -ConnectionBroker rds.informatiweb.lan
When you run this command, the "Publish RemoteApp program" message will appear temporarily in the PowerShell console.
Then, this :
Plain Text
CollectionName Alias DisplayName FilePath ShowIn CommandLin RequiredC Use WebAcc eSetting ommandLin rGr ess e oup s -------------- ----- ----------- -------- ------ ---------- --------- --- Office EXCEL Excel 2013 C:\Program Files\Microsoft Of... True DoNotAllow
Once the program(s) are published, you will find them in the collection in which you published them.
And you can also change their properties later, if you wish.
Windows Server 6/7/2019
Windows Server 3/8/2019
Windows Server 4/28/2019
Windows Server 3/16/2019
Pinned content
Contact
® InformatiWeb-Pro.net - InformatiWeb.net 2008-2022 - © Lionel Eppe - All rights reserved.
Total or partial reproduction of this site is prohibited and constitutes an infringement punishable by articles L.335-2 and following of the intellectual property Code.
You must be logged in to post a comment