Microsoft Teams is now generally available for Office 365 customers, and for those of you who are planning to use it you may be looking for a way to deploy the Teams client to your user’s computers.
The Microsoft Teams desktop client installer is available from Microsoft here. It’s a .exe package, with basic command-line switches for silent install and uninstall. For example, to silently install Microsoft Teams, the following command line can be used:
C:\temp\> Teams_windows_x64.exe -s
To silently uninstall Teams, the following command line can be used:
C:\temp> %userprofile%\AppData\Local\Microsoft\Teams\Update.exe" --uninstall -s
The Teams installer runs in the context of the logged on user and installs to the %userprofile%\AppData\Local\Microsoft\Teams folder, so any deployment script needs to run in the context of the user. A logon script assigned by Group Policy meets that requirement.
Teams is a self-updating application. It will check for, and download, any available updates each time the user runs the program. That makes it simple to maintain (as long as you allow it to self-update), and means that deploying Teams is basically a task of running the installer once, and then not running it again. So with a little scripting logic you can check for the existence of the Teams application in the user’s AppData folder, and run or not run the installer depending on the results.
As a side note, when Teams is uninstalled it leaves the Update.exe file in place. So checking for Update.exe in your script logic will give misleading results. Instead, you can check for the existence of a folder named “.dead”, which is placed in the application folder when Teams is uninstalled. For my deployment script which I’m sharing here, I’ve checked for “.dead”, and if found, will run the Teams installer again.
Preparing to Deploy Microsoft Teams
Before you deploy the Teams client you should verify that Teams in your Office 365 tenant is configured the way you want it. Teams configuration is demonstrated in my Getting Started with Microsoft Teams article.
Although Teams is included with eligible Office 365 plans, it can be enabled and disabled on a per-user basis. If you have had Teams disabled during the preview phase, now is the time to turn it back on. For my demonstration environment I’m using Azure AD group-based license management, and have an Active Directory group that is configured to enable the Teams option for users’ licenses. Helpfully, that also means I have a security group already in place that I can target my Group Policy to.
Download the Microsoft Teams installer and place the file on a network share that can be accessed by your users when the logon script runs. For this demonstration, the installer will be running from the path \\mgmt\installs\MicrosoftTeams.
Using Group Policy to Deploy Microsoft Teams
Download the Install-MicrosoftTeams.ps1 PowerShell script from the TechNet Script Gallery.
Create a Group Policy that assigns a logon script to run the Install-MicrosoftTeams.ps1 PowerShell script, and provide the -SourcePath as a script parameter.
If you are filtering the GPO to a specific security group, remember to also add Authenticated Users to the Delegation tab of the Group Policy and grant them Read (but not Apply) permissions.
At next Group Policy refresh and logon the Teams client will silently install for the user, and place a Microsoft Teams icon on their desktop.
The post Deploying the Microsoft Teams Desktop Client appeared first on Practical 365.