This is an automated archive made by the Lemmit Bot.
The original was posted on /r/sysadmin by /u/sysadmin_dot_py on 2023-10-07 02:41:03.
Just sharing case this helps others, or others can add their own input, but this is how we’re deploying the new Teams client and uninstalling the old Teams client with our deployment tools. I also included some of my notes.
Right now, the upgrade path that uses Teams Update Policies in the TAC assumes the user has the old Teams client installed. I wanted a mechanism that I fully control with my standard deployment tools and that I can use to install the new Teams client directly on new computers without installing and upgrading the old client first.
- Make sure your users’ Teams Update policy setting “Use new Teams client” is NOT set to “Not enabled” (in the TAC, that is under Teams > Teams Update Policies).
- Bulk deploy the new Teams using the bootstrapper from Microsoft. Run
teamsbootstrapper.exe -p
with your deployment tool of choice, with elevated or SYSTEM privileges. Do not run as the user. This installsMSTeams
as a provisioned packaged (Get-AppxProvisionedPackage -Online
). - When users log in next, the the app will be provisioned within the user profile.
- If you use the old Teams Machine-Wide installer, uninstall that with your deployment tool (perhaps in the same deployment package/script as the above and again, run with elevated or SYSTEM privileges):
MsiExec.exe /qn /norestart /X{731F6BAA-A986-45A4-8936-7C3AAAAA760B}
5. Lastly, you need to actually uninstall the old Teams client, which is installed in each user’s profile. You can deploy the following script to run as the user using your preferred tool, or if your tool does not allow, run this in a logon script, or deploy a scheduled task that runs as the logged in user and triggers when the user logs in. The script checks whether both Teams clients are installed for the current user, and if so, uninstalls the old client from the user profile.
if ((Get-AppxPackage -Name MSTeams) -and (Test-Path "$($env:LOCALAPPDATA)\Microsoft\Teams\current\Teams.exe")) {
& "$($env:LOCALAPPDATA)\Microsoft\Teams\Update.exe" --uninstall -s
}
If you just want to use the policies in the TAC to force the new version, you can do that too, and just perform the last couple of steps to remove the old client.
Hope this helps :)