Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide Example, Add Support for 'New' Teams #772

Open
DevopsMercenary opened this issue Jan 18, 2024 · 1 comment
Open

Provide Example, Add Support for 'New' Teams #772

DevopsMercenary opened this issue Jan 18, 2024 · 1 comment

Comments

@DevopsMercenary
Copy link

It's only a few months until new teams is the law of the land.

I've been using your awesome scripts as follows for the existing "old" teams which works great...

        {
          destination    = "C:\\AVDImage\\TeamsOptimization.ps1",
          name           = "avdBuiltInScript_teamsOptimization",
          sha256Checksum = "586f824ae79916322287f69a4daaf9a91939272509cdd39d4b032bd0fa8eb8b2",
          sourceUri      = "https://raw.githubusercontent.com/Azure/RDS-Templates/master/CustomImageTemplateScripts/CustomImageTemplateScripts_2023-11-20/TeamsOptimization.ps1",
          type           = "File"
        },
        {
          inline = [
             "C:\\AVDImage\\TeamsOptimization.ps1 -TeamsDownloadLink \"https://teams.microsoft.com/downloads/desktopurl?env=production&plat=windows&arch=x64&managedInstaller=true&download=true\" -WebRTCInstaller \"https://aka.ms/msrdcwebrtcsvc/msi\" -VCRedistributableLink \"https://aka.ms/vs/17/release/vc_redist.x64.exe\""
          ],
          name        = "avdBuiltInScript_teamsOptimization-parameter",
          runAsSystem = true,
          runElevated = true,
          type        = "PowerShell"
        },

BUT, I don't want to have to update this image in a few months. I would like to get started with new teams.....

SO, I took a guess at how to do it using the existing infra

        {
          destination    = "C:\\AVDImage\\TeamsOptimization.ps1",
          name           = "avdBuiltInScript_teamsOptimization",
          sha256Checksum = "586f824ae79916322287f69a4daaf9a91939272509cdd39d4b032bd0fa8eb8b2",
          sourceUri      = "https://raw.githubusercontent.com/Azure/RDS-Templates/master/CustomImageTemplateScripts/CustomImageTemplateScripts_2023-11-20/TeamsOptimization.ps1",
          type           = "File"
        },
        {
          inline = [
            "C:\\AVDImage\\TeamsOptimization.ps1 -TeamsDownloadLink \"https://go.microsoft.com/fwlink/?linkid=2196106\" -WebRTCInstaller \"https://aka.ms/msrdcwebrtcsvc/msi\" -VCRedistributableLink \"https://aka.ms/vs/17/release/vc_redist.x64.exe\""
          ],
          name        = "avdBuiltInScript_teamsOptimization-parameter",
          runAsSystem = true,
          runElevated = true,
          type        = "PowerShell"
        },

And it did 'install' new teams but it's not really there or installed from what I can tell. The Icon is there in the start menu, but new teams doesn't start automatically nor can I start it from clicking the icon.

I would appreciate the update or at least some direction on how to install NEW teams

@DevopsMercenary
Copy link
Author

Trying a few different things....

I made a local copy of TeamsOptimization.psi and updated it to run the teamsbootstrapper instead.

At line 65

                #Install NEW Teams using the bootstrapper 
                $teamsExe = 'teamsbootstrapper.exe'
                $outputPath = $LocalPath + '\' + $teamsExe
                Invoke-WebRequest -Uri $TeamsDownloadLink -OutFile $outputPath
                Start-Process -FilePath $outputPath -Args " -p " -Wait
                Write-host "AVD AIB Customization: Teams Optimization - Finished installation of Teams"

Invoke it during the azure image builder with

            "C:\\AVDImage\\TeamsOptimization.ps1 -TeamsDownloadLink \"https://go.microsoft.com/fwlink/?linkid=2243204&clcid=0x409\" -WebRTCInstaller \"https://aka.ms/msrdcwebrtcsvc/msi\" -VCRedistributableLink \"https://aka.ms/vs/17/release/vc_redist.x64.exe\""

And it does 'install' it.

Logs...

2024-01-18T16:38:34.795182Z  INFO teamsprovision_lib::os_build: OS Build: 10.0.19045.3930
2024-01-18T16:38:34.795263Z  INFO teamsprovision_lib::check_install: OS supported.
2024-01-18T16:38:34.795266Z  INFO teamsbootstrapper: Starting Teams provisioning.
2024-01-18T16:38:34.795279Z  INFO teamsprovision_lib::os_build: OS Build: 10.0.19045.3930
2024-01-18T16:38:34.795281Z  INFO teamsprovision_lib::check_install: Windows GPO patch detected.
2024-01-18T16:38:35.059407Z  INFO StagePackageByUriAsync: teamsprovision_lib::packaging: enter
2024-01-18T16:38:35.059435Z  INFO StagePackageByUriAsync: teamsprovision_lib::teams_package: Detected system arch: Some(X64)
2024-01-18T16:38:35.259249Z  INFO StagePackageByUriAsync: teamsprovision_lib::packaging: exit
2024-01-18T16:39:23.697073Z  INFO StagePackageByUriAsync: teamsprovision_lib::packaging: enter
2024-01-18T16:39:23.697161Z  INFO StagePackageByUriAsync: teamsprovision_lib::packaging: exit
2024-01-18T16:39:23.697183Z  INFO ProvisionPackageForAllUsersAsync: teamsprovision_lib::packaging: enter
2024-01-18T16:39:23.722819Z  INFO ProvisionPackageForAllUsersAsync: teamsprovision_lib::packaging: exit
2024-01-18T16:39:23.879085Z  INFO ProvisionPackageForAllUsersAsync: teamsprovision_lib::packaging: enter
2024-01-18T16:39:23.879164Z  INFO ProvisionPackageForAllUsersAsync: teamsprovision_lib::packaging: exit
2024-01-18T16:39:23.879197Z  INFO do_post_install_actions: teamsprovision_lib::postinstall_actions: enter
2024-01-18T16:39:23.879203Z  INFO do_post_install_actions:write_post_install_regkeys: teamsprovision_lib::postinstall_actions: enter
2024-01-18T16:39:23.879524Z  INFO do_post_install_actions:write_post_install_regkeys: teamsprovision_lib::postinstall_actions: exit
2024-01-18T16:39:23.879531Z  INFO do_post_install_actions: teamsprovision_lib::postinstall_actions: exit

But clicking on the Icon in the start menu doesn't do anything.

But, if I run it again while logged into the new VM it will install correctly and allow me to start it from the icon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant