Office 365 Deployment - Office 365 Upgrade Task Sequence

Office 365 by its self is a fairly easy Application to deploy but it can get complicated when you need to remove other Office products or install different versions of Office 365 based on what was installed on the target device. That all being said I wanted to create a reference for getting all the tools that make office deployments easy and throw in a few tips to solve some more unique issues you may have with deploying Office 365.

1. The first thing you want to do is download the Office Deployment Tool. Once you install the Tool you will find a setup.exe file and a configuration.xml.

2. The configuration file controls what will be installed and what will be downloaded. For example if the download switch is used with the configuration file below then Office 365 ProPlus x32 and VisioPro x32 will be downloaded. If you use that same configuration file with the configure switch then ProPlus x32 and VisioPro x32 will be installed from \\Server\Share with the EULA accepted and only the progress off the install will show to the user. 


<!-- Office 365 client configuration file sample. To be used for Office 365 ProPlus 2016 apps, 
     Office 365 Business 2016 apps, Project Pro for Office 365 and Visio Pro for Office 365. 

     For detailed information regarding configuration options visit: http://aka.ms/ODT. 
     To use the configuration file be sure to remove the comments

     For Office 365 client apps (verion 2013) you will need to use the 2013 version of the 
     Office Deployment Tool which can be downloaded from http://aka.ms/ODT2013

     The following sample allows you to download and install Office 365 ProPlus 2016 apps 
     and Visio Pro for Office 365 directly from the Office CDN using the Current Channel
     settings  -->



<Configuration>

  <Add OfficeClientEdition="32" Channel="Current">
    <Product ID="O365ProPlusRetail">
      <Language ID="en-us" />
    </Product>
    <Product ID="VisioProRetail">
      <Language ID="en-us" />
    </Product>
  </Add>

  <!--  <Updates Enabled="TRUE" Channel="Current" /> -->

  <Display Level="Basic" AcceptEULA="TRUE" />

  <Property Name="AUTOACTIVATE" Value="1" />

</Configuration>


You can get more information about what can be included in the configuration file from HERE

You can run the download process by running setup.exe /download config.xml

3. Once you have your bits downloaded and your configuration file set you will want to get the Office Scrub scrip's from the Office Dev Teams GitHub page There is also a lot of other information and tools included with there scripts that can be vary useful as well.

Office 365 Application

Next I will guide you through how to build a Office 365 Application

1. Create a folder where you keep your SCCM content called Office365Bits and copy the Office folder containing the Office 365 bits here.

2. In your Configuration file put the FQDN to the Office Folder for the SourcePath should look something like \\Server\Share\Office365Bits\

3. Create a folder where you keep your SCCM content called Office365 and copy your configuration file the setup file and the OffScrubc2r.vbs ,located at Office-IT-Pro-Deployment-Scripts-master\Office-ProPlus-Deployment\Remove-PreviousOfficeInstalls, to the Office365 folder.

4. Open your SCCM Admin Console and create a new application. Choose "Manually specify the application information" click next



5. Use the following for the application info
  • Name: Office 365
  • Publisher: Microsoft
  • Software Version: x86
  • Check the box to allow the application to be installed from the Application task sequence without being deployed

6. Add any information you need in the Application Catalog entry I always like to Add an Icon add some text to the description and for the link text I put the Office Support Site.



7. When you get to the deployment Types click add


8. Change the type to Scrip Installer and click next, Name the Installer "Office 365 Installer" click next

9. Use the Following for the Content
  • Content Location: Path to folder you created in step 3
  • Install Program: "setup.exe" /configure confi.xml
  • Uninstall Program: "OffScrubc2r.vbs" /log C:\windows\ccm\logs\Office365 /Quiet
10. For the Detection method click add Clause. Use the Following settings
  • Setting Type: Registry
  • Hive: HKEY_LOCAL_MACHINE
  • Key: Software\Microsoft\Windows\CurrentVersion\Uninstall\O365ProPlusRetail - en-us
  • Check "Use (Default) registry key value for detection"
  • Data Type: String

11. For user experience change the Installation behavior to Install for system and change Logon requirements to Whether or not a user is logged on.


12. Click Next until you get the completion page and close the wizard, Then complete the application. Distribute your Application to all your DPs.



Office Scrub Package
We will now create a package from the Remove-PreviousOfficeInstalls.ps1 script that came in the office scrub scripts.

1. Where you keep your SCCM content create a folder called Remove-PreviousOfficeInstalls.

2. Copy the following files from the Office Scrub Scripts you downloaded. Should be located at Office-IT-Pro-Deployment-Scripts-master\Office-ProPlus-Deployment\Remove-PreviousOfficeInstalls.
  • OffScrub03.vbs
  • OffScrub07.vbs
  • OffScrub10.vbs
  • OffScrubc2r.vbs
  • OffScrub_O15msi.vbs
  • OffScrub_O16msi.vbs
  • Remove-PreviousOfficeInstalls.ps1
3. Create a new package Name it Remove Office Installs and check "This package contains source files". Then click next


4. Choose "Do not create a program". Click next till the package is complete


5. Distribute the Remove Office Installs package to your DPs.



Office 365 Upgrade TS
 
Now I will show you what you want in your Office 365 Upgrade Task Sequence.
The  TS will uninstall your old versions of office and clean up any files that could hinder the upgrade process.

1. Create a new custom Task Sequence

2. Click Next, Name the TS Office 365 Upgrade and click next

3. Open your TS and click add Under general choose the Restart Computer Task

4. In the Restart Computer Task Change what to run after restart option to "The currently installed default operating system. By doing this we can be sure that the user is not working in Office when the upgrade happens. You may want to add some information in the Notification message and you can change how long the message will show before the computer reboots by adding to the Message display time-out.


5. Next add a Run Command Line task, name the task Removing Old Office and use the following for the command line:
powershell.exe -ExecutionPolicy Bypass -Command .\Remove-PreviousOfficeInstalls.ps1 -Quiet $False -Remove2016Installs $True -KeepUserSettings $True -NoReboot $True

Then check the Package box and browse to your Remove Office Installs package.


6. Now add a install application task and browse for your Office 365 Application click apply. That is is your Office 365 Upgrade TS is Complete.


If you need Still need old office products you must use the stand alone installer for that product. To add them to this TS create a application for the stand alone installer and place it right before the install 365Office task. 

Popular posts from this blog

SCCM Task Sequence GUI - How to set up the TS to work with a GUI

Windows 10 Setup Script - Version 2.5.0.1

SCCM Applications vs. SCCM Packages: Understanding the Key Differences