Page 1 of 1

Office 2019 package

Published: October 30, 2020 - 10:20 AM
by gaelds
Good morning,
I used the example of the package for Office 2019 which seemed to work here:
viewtopic.php?f=9&t=2407&p=7967&hilit=office+2019#p7967
but I'm still getting the error:
CalledProcessErrorOutput: Command '"setup.exe" /configure "configuration-office2019.xml"' returned non-zero exit status -2146994714.

Here is my setup.py:

Code: Select all

# -*- coding: utf-8 -*-
from setuphelpers import *
# You should also check for the uninstall string for uninstall_args by using : wapt-get list-registry Office

uninstallkey = []

# raccourcis
RaccourcisDossierProgramm1 = makepath(programfiles32,"Microsoft Office","root","Office16")

softname = "Microsoft Office Professional Plus 2019 - fr-fr"
pgmsoffice = programfiles
uninstall_args = r'scenario=install scenariosubtype=ARP sourcetype=None productstoremove=ProPlus2019Volume.16_fr-fr_x-none culture=fr-fr version.16=16.0 DisplayLevel=False'

kill_list = ['winword.exe','powerpnt.exe','excel.exe','mspub.exe','msaccess.exe','infopath.exe','lync.exe','onenote.exe','outlook.exe','onenotem.exe','msosync.exe','groove.exe','OfficeClicktoRun.exe']

def install():
    office_installed = installed_softwares(softname)
    cmd = '"setup.exe" /configure "configuration-office2019.xml"'

    if not office_installed:
        print('Installation de {}'.format(softname))
        run(cmd,timeout=1200,accept_returncodes=[1641,3010,0])
    else:
        if Version(office_installed[0]['version']) < Version(control.version.split('-',1)[0]):
            run(cmd,timeout=1200,accept_returncodes=[1641,3010,0])
        else:
            print('{} already up to date or newer : {}'.format(softname,office_installed[0]['version']))

    if not installed_softwares(softname):
        error(' {} has been installed but the uninstall key can not be found'.format(softname))

    print('Copie des fichiers de desinstallation uninstall-all.XML et setup.exe')
    copytree2(r"uninstall",(RaccourcisDossierProgramm1))

def uninstall():
    print('Removing {}'.format(softname))
    for soft in kill_list:
        killalltasks(soft)

    uninstallcmd = r'"C:\Program Files (x86)\Microsoft Office\root\Office16\setup.exe" /configure "C:\Program Files (x86)\Microsoft Office\root\Office16\uninstall-all.xml"'
    print('desinstallation de Microsoft Office')
    run(uninstallcmd,timeout=1800,accept_returncodes=[1641,3010,0])
    print('fin de uninstall')
And the configuration-office2019.xml file:

Code: Select all

<Configuration>
  <Add OfficeClientEdition="64" Channel="PerpetualVL2019" SourcePath="\\172.16.10.3\Logiciels\Office2019\" AllowCdnFallback="TRUE">
    <Product ID="ProPlus2019Volume" PIDKEY="xxxxxxxxxxxxxxxxxxxxx">
      <Language ID="fr-fr" />
      <ExcludeApp ID="Groove" />
      <ExcludeApp ID="OneDrive" />
      <ExcludeApp ID="Outlook" />
    </Product>
    <Product ID="LanguagePack">
      <Language ID="fr-fr" />
      <ExcludeApp ID="Groove" />
      <ExcludeApp ID="OneDrive" />
      <ExcludeApp ID="Outlook" />
    </Product>
    <Product ID="ProofingTools">
      <Language ID="fr-fr" />
	  <Language ID="de-de" />
      <Language ID="en-us" />
	  <Language ID="es-ES" />
    </Product>
  </Add>
  <Property Name="SharedComputerLicensing" Value="0" />
  <Property Name="PinIconsToTaskbar" Value="FALSE" />
  <Property Name="SCLCacheOverride" Value="0" />
  <Property Name="AUTOACTIVATE" Value="1" />
  <Property Name="FORCEAPPSHUTDOWN" Value="TRUE" />
  <Property Name="DeviceBasedLicensing" Value="0" />
  <Updates Enabled="TRUE" UpdatePath="\\172.16.10.3\Logiciels\Office2019\Updates\" />
  <AppSettings>
    <Setup Name="Company" Value="XXX" />
    <User Key="software\microsoft\office\16.0\common\toolbars" Name="screentipscheme" Value="2" Type="REG_DWORD" App="office16" Id="L_ShowScreenTips" />
    <User Key="software\microsoft\office\16.0\excel\options" Name="defaultformat" Value="51" Type="REG_DWORD" App="excel16" Id="L_SaveExcelfilesas" />
    <User Key="software\microsoft\office\16.0\powerpoint\options" Name="defaultformat" Value="27" Type="REG_DWORD" App="ppt16" Id="L_SavePowerPointfilesas" />
    <User Key="software\microsoft\office\16.0\word\options" Name="defaultformat" Value="" Type="REG_SZ" App="word16" Id="L_SaveWordfilesas" />
  </AppSettings>
  <Display Level="None" AcceptEULA="TRUE" /> 
  <Logging Level="Off" />
</Configuration>

Re: Office 2019 package

Published: October 30, 2020 - 11:29 AM
by gaelds
The following command, run manually, works on the machines:
\\172.16.10.3\Logiciels\Office2019\setup.exe /configure \\172.16.10.3\Logiciels\Office2019\configuration-office2019.xml.


So I suspect the system account used by wapt might not have access to the network share... Therefore, the "SourcePath" in the configuration XML file needs to be changed, but I've tried "./office", "office", and ".\office". Nothing works.

Re: Office 2019 package

Published: November 6, 2020 - 11:49 AM
by gaelds
I still don't see a solution. The command launched from the network share works:
"\\172.16.10.3\logiciels\Office2019\setup.exe /configure /configuration-office2019.xml" installs Office correctly.
But when setup.exe and the configuration-office2019.xml file are copied locally, it doesn't work.
"C:\temp\setup.exe /configure /configuration-office2019.xml"
displays error 30088-1021 (0).
I imagine it's the same error that prevents installation via the package.

Re: Office 2019 package

Published: November 6, 2020 - 12:06 PM
by dcardon
This forum and the WAPT documentation clearly state that accessing network shares for package installation is strongly discouraged. The installation doesn't necessarily occur when the machine has network access, and more specifically, access to the server in question (machine connected via Wi-Fi, 802.1x, VPN), or the connection credentials might not match (the WAPT agent runs on LocalSystem, which isn't always well integrated). It's much better to include the executable files in the package (or create two separate packages if it's a real problem, for example, if you frequently change the installation parameters).
Regards,
Denis

Re: Office 2019 package

Published: November 9, 2020 - 2:36 PM
by gaelds
OK, thanks for the reply! But could you tell me what to put for SourcePath? I've tried adding the "office" folder containing the installation files to the package, and using SourcePath="office", SourcePath="./office", and SourcePath=".\office", but nothing works...

Re: Office 2019 package

Published: November 20, 2020 - 09:21
by TeoMrbl
Hello,


I'm reviving this thread.
Has there been any progress on this package? I'm currently experiencing the same issue as you.

Looking forward to your reply,


Best regards,

Have a good day!

Re: Office 2019 package

Published: November 23, 2020 - 10:33 AM
by gaelds
I just managed to install the package on one machine using the command "wapt-get install --direct -ldebug". Office installed correctly, but the installation window was visible despite the instruction `Display Level="NONE"` in the "configuration-office2019.xml" file

Code: Select all

<Configuration>
  <Add OfficeClientEdition="64" Channel="PerpetualVL2019" SourcePath="Office" AllowCdnFallback="TRUE">
    <Product ID="ProPlus2019Volume" PIDKEY="XXXXXXXXXXXXXXXXXXXXXXXXXXX">
      <Language ID="fr-fr" />
      <ExcludeApp ID="OneDrive" />
      <ExcludeApp ID="Outlook" />
    </Product>
    <Product ID="LanguagePack">
      <Language ID="fr-fr" />
      <ExcludeApp ID="OneDrive" />
      <ExcludeApp ID="Outlook" />
    </Product>
    <Product ID="ProofingTools">
      <Language ID="fr-fr" />
	  <Language ID="de-de" />
      <Language ID="en-us" />
	  <Language ID="es-ES" />
    </Product>
  </Add>
  <Property Name="SharedComputerLicensing" Value="0" />
  <Property Name="PinIconsToTaskbar" Value="FALSE" />
  <Property Name="SCLCacheOverride" Value="0" />
  <Property Name="AUTOACTIVATE" Value="1" />
  <Property Name="FORCEAPPSHUTDOWN" Value="TRUE" />
  <Property Name="DeviceBasedLicensing" Value="0" />
  <Updates Enabled="TRUE" UpdatePath="Updates" />
  <AppSettings>
    <Setup Name="Company" Value="DOM SORTAIS" />
    <User Key="software\microsoft\office\16.0\common\toolbars" Name="screentipscheme" Value="2" Type="REG_DWORD" App="office16" Id="L_ShowScreenTips" />
    <User Key="software\microsoft\office\16.0\excel\options" Name="defaultformat" Value="51" Type="REG_DWORD" App="excel16" Id="L_SaveExcelfilesas" />
    <User Key="software\microsoft\office\16.0\powerpoint\options" Name="defaultformat" Value="27" Type="REG_DWORD" App="ppt16" Id="L_SavePowerPointfilesas" />
    <User Key="software\microsoft\office\16.0\word\options" Name="defaultformat" Value="" Type="REG_SZ" App="word16" Id="L_SaveWordfilesas" />
  </AppSettings>
  <Display Level="NONE" AcceptEULA="TRUE" /> 
  <Logging Level="Off" />
</Configuration>

Re: Office 2019 package

Published: November 23, 2020 - 1:50 PM
by gaelds
And here are the logs when I do a simple "wapt-get install dst-microsoft-office"
Installing dst-microsoft-office(=16.0.13231.20350-22)
Removing the office application from win10 from
Installing Microsoft Office Professional Plus 2019 - fr-fr
2020-11-23 14:56:52,713 CRITICAL Fatal error in install script: CalledProcessErrorOutput: Command '"c:\\users\\adm\\appdata\\local\\temp\\waptg1exkt\\setup.exe" /configure "./configuration-office2019.xml"' returned non-zero exit status -2147418113.
Output::
Traceback (most recent call last):
File "C:\wapt\common.py", line 3876, in install_wapt
exitstatus = setup.install()
File "c:\users\adm\appdata\local\temp\waptg1exkt\setup.py", line 24, in install
run(cmd,timeout=1200,accept_returncodes=[1641,3010,0])
File "C:\wapt\common.py", line 3646, in run
return ensure_unicode(setuphelpers.run(*arg,**args))
File "C:\wapt\setuphelpers_windows.py", line 3716, in run
raise CalledProcessErrorOutput(proc.returncode,cmd,''.join(output))
CalledProcessErrorOutput: Command '"c:\\users\\adm\\appdata\\local\\temp\\waptg1exkt\\setup.exe" /configure "./configuration-office2019.xml"' returned non-zero exit status -2147418113.
Output:

2020-11-23 14:56:53,641 CRITICAL Package dst-microsoft-office [x64_fr_PROD] not installed due to errors: CalledProcessErrorOutput: Command '"c:\\users\\adm\\appdata\\local\\temp\\waptg1exkt\\setup.exe" /configure "./configuration-office2019.xml"' returned non-zero exit status -2147418113.
Output:


Re: Office 2019 package

Published: March 3, 2021 - 4:23 PM
by florentR2
Having also struggled with this same problem, the very simple solution that worked for me was to empty the SourcePath like this:

Code: Select all

SourcePath=""