tis-limit-windows-update-bandwidth

1.0-2
Limit the bandwidth used by Windows Update
493 downloads
Download

  Description 

  • package : tis-limit-windows-update-bandwidth
  • version : 1.0-2
  • architecture : all
  • categories :
  • maintainer : Kevin Guerineau
  • description : Limit the bandwidth used by Windows Update
  • locale : all
  • target_os : windows
  • min_wapt_version : 1.5
  • sources :
  • installed_size :
  • impacted_process :
  • description_fr : Limiter la bande-passante utilisee par Windows Update
  • description_pl :
  • description_de :
  • description_es :
  • description_pt :
  • description_it :
  • description_nl :
  • description_ru :
  • editor :
  • licence :
  • signature_date : 2020-02-27T21:35:28.261258

  Setup.py 

# -*- coding: utf-8 -*-
from setuphelpers import *

uninstallkey = []

def install():
    print('installing %s' % control.asrequirement())
    # put here what to do when package is installed on host
    # implicit context variables are WAPT, basedir, control, user, params, run
    registry_setstring(HKEY_LOCAL_MACHINE,"SOFTWARE\\Policies\\Microsoft\\Windows\\DeliveryOptimization","DOMaxDownloadBandwidth",500,type=REG_DWORD)
    registry_setstring(HKEY_LOCAL_MACHINE,"SOFTWARE\\Policies\\Microsoft\\Windows\\DeliveryOptimization","DOMaxUploadBandwidth",30,type=REG_DWORD)


def uninstall():
    print('uninstalling %s' % control.asrequirement())
    # put here what to do when package is removed from host
    # implicit context variables are WAPT, control, user, params, run
    registry_deletekey(HKEY_LOCAL_MACHINE,"SOFTWARE\\Policies\\Microsoft\\Windows","DeliveryOptimization")

def session_setup():
    print('Session setup for %s' % control.asrequirement())
    # put here what to do when package is configured inside a user session
    # implicit context variables are WAPT, control, user, params

def update_package():
    print('Update package content from upstream binary sources')
    # put here what to do to update package content with newer installers.
    # launched with command wapt-get update-package-sources <path-to-wapt-directory>
    # implicit context variables are WAPT, basedir, control, user, params, run
    # if attributes in control are changed, they should be explicitly saved to package file with control.save_control_to_wapt()

def audit():
    print('Auditing %s' % control.asrequirement())
    # put here code to check periodically that state is matching expectations
    # return "OK", "WARNING" or "ERROR" to report status in console.
    # all print statement are reported too

if __name__ == '__main__':
    update_package()


										

  Changelog 



No changelog.txt.
									
  manifest.sha256