2021-07-27 11:29:37 -04:00
|
|
|
## Path to the MSI installer
|
2021-07-08 12:57:09 -04:00
|
|
|
$MSIURL = 'https://dev.emberkom.com/emberkom/management-scripts/raw/branch/master/resources/LiquidFiles_Admin_2.0.129.msi'
|
2020-07-31 12:44:03 -04:00
|
|
|
|
|
|
|
|
## Set installer args
|
2021-08-10 13:28:34 -04:00
|
|
|
If ( $LFHost ) {
|
|
|
|
|
LogMsg "LiquidFiles target server: ${LFHost}"
|
|
|
|
|
$INSTALLER_ARGS = "REGKEYSCRIPT=""BaseUrl=${LFHost};"""
|
2020-07-31 12:44:03 -04:00
|
|
|
}
|
|
|
|
|
Else { $INSTALLER_ARGS = '' }
|
|
|
|
|
|
|
|
|
|
## Run the installer
|
2021-05-06 11:57:17 -04:00
|
|
|
$INSTALLER = Download-File -URL $MSIURL
|
|
|
|
|
LogMsg "Installing Liquid Files Outlook Agent from ""${INSTALLER}"""
|
|
|
|
|
Try { Start-Process "msiexec.exe" -ArgumentList "/i ${INSTALLER} /qn /norestart ${INSTALLER_ARGS}" -Wait -ErrorAction Stop }
|
|
|
|
|
Catch { LogErr $_.Exception.Message }
|
|
|
|
|
|
|
|
|
|
## Delete installer
|
|
|
|
|
Try {
|
2021-05-24 14:05:59 -04:00
|
|
|
LogMsg "Deleting downloaded installation package"
|
|
|
|
|
Remove-Item $INSTALLER -Force -ErrorAction SilentlyContinue
|
2021-05-06 11:57:17 -04:00
|
|
|
}
|
|
|
|
|
Catch { LogErr $_.Exception.Message }
|