Fix audit as now fusinv_servers is a list

master
Daniel Berteaud 6 years ago
parent 911b7dc80f
commit 3ac39d2044
  1. 8
      WAPT/control
  2. 4
      setup.py

@ -1,9 +1,9 @@
package : fws-fusioninventory package : fws-fusioninventory
version : 2.4.2-9 version : 2.4.2-10
architecture : all architecture : all
section : base section : base
priority : optional priority : optional
maintainer : Kevin Guerineau maintainer : Daniel Berteaud
description : FusionInventory is a computer inventory agent description : FusionInventory is a computer inventory agent
depends : depends :
conflicts : conflicts :
@ -20,9 +20,9 @@ description_fr : FusionInventory est un agent d'inventaire d'ordinateurs
description_pl : description_pl :
description_de : description_de :
description_es : description_es :
audit_schedule : 4w audit_schedule : 2d
editor : editor :
keywords : keywords : inventory
licence : GPLv2+ licence : GPLv2+
homepage : http://fusioninventory.org/ homepage : http://fusioninventory.org/
package_uuid : package_uuid :

@ -84,8 +84,8 @@ def audit():
print(r"key HKEY_LOCAL_MACHINE\SOFTWARE\FusionInventory-Agent\server doesn't exist") print(r"key HKEY_LOCAL_MACHINE\SOFTWARE\FusionInventory-Agent\server doesn't exist")
return "ERROR" return "ERROR"
val_server = registry_readstring(HKEY_LOCAL_MACHINE,makepath('SOFTWARE','FusionInventory-Agent'),'server') val_server = registry_readstring(HKEY_LOCAL_MACHINE,makepath('SOFTWARE','FusionInventory-Agent'),'server')
if val_server != variables['fusinv_servers'] : if val_server != ','.join(variables['fusinv_servers']) :
print("server config is not %, it's % instead" % (variables['fusinv_servers'], val_server) ) print("server config is not %, it's % instead" % (','.join(variables['fusinv_servers']), val_server) )
return "WARNING" return "WARNING"
if 'fusinv_user' in variables and 'fusinv_pass' in variables: if 'fusinv_user' in variables and 'fusinv_pass' in variables:
if not registry_readstring(HKEY_LOCAL_MACHINE,makepath('SOFTWARE','FusionInventory-Agent'),'user'): if not registry_readstring(HKEY_LOCAL_MACHINE,makepath('SOFTWARE','FusionInventory-Agent'),'user'):

Loading…
Cancel
Save