Store full ESET installer
* Allows for offline installs * Avoids excessive downloads of the installer * Fixes issue #71
This commit is contained in:
parent
67c5384e5b
commit
a43c705f28
3 changed files with 22 additions and 15 deletions
|
|
@ -199,26 +199,16 @@ def install_eset_nod32_av(scan_pups=True):
|
|||
# Apply user configuration
|
||||
write_registry_settings(SETTINGS_ESET, all_users=False)
|
||||
|
||||
# Download
|
||||
result = try_and_print(message='Downloading Setup...', cs='Done',
|
||||
other_results=OTHER_RESULTS, function=download_generic,
|
||||
out_dir=global_vars['ClientDir'],
|
||||
out_name='eav_nt64.exe',
|
||||
source_url=SOURCE_URLS['ESET NOD32 AV'])
|
||||
installer = r'{ClientDir}\eav_nt64.exe'.format(**global_vars)
|
||||
if not result['CS']:
|
||||
raise GenericError('Failed to download ESET NOD32 AV')
|
||||
|
||||
# Install
|
||||
cmd = [installer,
|
||||
cmd = [
|
||||
r'{}\Installers\Extras\Security\ESET NOD32 x64.exe'.format(
|
||||
global_vars['BaseDir']),
|
||||
'--silent', '--accepteula', '--msi-property',
|
||||
'PRODUCTTYPE=eav', 'PRODUCT_LANG=1033', 'PRODUCT_LANG_CODE=en-US',
|
||||
'ADMINCFG="{}"'.format(config_file)]
|
||||
'ADMINCFG="{}"'.format(config_file),
|
||||
]
|
||||
try_and_print(message='Installing ESET NOD32 AV...',
|
||||
other_results=OTHER_RESULTS, function=run_program, cmd=cmd)
|
||||
|
||||
# Delete installer
|
||||
remove_item(installer)
|
||||
|
||||
def install_firefox_extensions():
|
||||
"""Install Firefox extensions for all users."""
|
||||
|
|
|
|||
|
|
@ -703,6 +703,22 @@ def update_eset_config():
|
|||
shutil.copytree(include_path, dest)
|
||||
|
||||
|
||||
def update_eset_nod32():
|
||||
# Prep
|
||||
dest = r'{}\Installers\Extras\Security'.format(
|
||||
global_vars['BaseDir'])
|
||||
|
||||
# Remove existing installer
|
||||
try:
|
||||
os.remove(r'{}\ESET NOD32 x64.exe'.format(dest))
|
||||
except FileNotFoundError:
|
||||
pass
|
||||
|
||||
# Download
|
||||
download_generic(
|
||||
dest, 'ESET NOD32 x64.exe', SOURCE_URLS['ESET NOD32 AV'])
|
||||
|
||||
|
||||
def update_libreoffice():
|
||||
# Prep
|
||||
dest = r'{}\Installers\Extras\Office'.format(
|
||||
|
|
|
|||
|
|
@ -60,6 +60,7 @@ if __name__ == '__main__':
|
|||
print_info(' Installers')
|
||||
try_and_print(message='Adobe Reader DC...', function=update_adobe_reader_dc, other_results=other_results, width=40)
|
||||
try_and_print(message='ESET Configs...', function=update_eset_config, other_results=other_results, width=40)
|
||||
try_and_print(message='ESET NOD32...', function=update_eset_nod32, other_results=other_results, width=40)
|
||||
try_and_print(message='LibreOffice...', function=update_libreoffice, other_results=other_results, width=40)
|
||||
try_and_print(message='Macs Fan Control...', function=update_macs_fan_control, other_results=other_results, width=40)
|
||||
try_and_print(message='MS Office...', function=update_office, other_results=other_results, width=40)
|
||||
|
|
|
|||
Loading…
Reference in a new issue