PNG  IHDR;IDATxܻn0K )(pA 7LeG{ §㻢|ذaÆ 6lذaÆ 6lذaÆ 6lom$^yذag5bÆ 6lذaÆ 6lذa{ 6lذaÆ `}HFkm,mӪôô! x|'ܢ˟;E:9&ᶒ}{v]n&6 h_tڠ͵-ҫZ;Z$.Pkž)!o>}leQfJTu іچ\X=8Rن4`Vwl>nG^is"ms$ui?wbs[m6K4O.4%/bC%t Mז -lG6mrz2s%9s@-k9=)kB5\+͂Zsٲ Rn~GRC wIcIn7jJhۛNCS|j08yiHKֶۛkɈ+;SzL/F*\Ԕ#"5m2[S=gnaPeғL lذaÆ 6l^ḵaÆ 6lذaÆ 6lذa; _ذaÆ 6lذaÆ 6lذaÆ RIENDB` #!/usr/bin/python import json import subprocess if __name__ == '__main__': activeAccounts = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/cpanel.actacc", shell=True, stdout=subprocess.PIPE).communicate()[0] allAccounts = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/cpanel.allacc", shell=True, stdout=subprocess.PIPE).communicate()[0] suspendedAccounts = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/cpanel.susacc", shell=True, stdout=subprocess.PIPE).communicate()[0] bothits = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/bot.hits", shell=True, stdout=subprocess.PIPE).communicate()[0] allhits = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.hits", shell=True, stdout=subprocess.PIPE).communicate()[0] allprof = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.profe", shell=True, stdout=subprocess.PIPE).communicate()[0] allbuis = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.buies", shell=True, stdout=subprocess.PIPE).communicate()[0] allstart = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.start", shell=True, stdout=subprocess.PIPE).communicate()[0] allsumm = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.summer", shell=True, stdout=subprocess.PIPE).communicate()[0] allrain = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.rain", shell=True, stdout=subprocess.PIPE).communicate()[0] allstorm = subprocess.Popen("cat /etc/zabbix/scripts/.tmp/all.storm", shell=True, stdout=subprocess.PIPE).communicate()[0] data = { 'Activeaccounts' : activeAccounts.replace('\n',''), 'Allaccounts' : allAccounts.replace('\n',''), 'Suspendedaccounts' : suspendedAccounts.replace('\n',''), 'BotHits' : bothits.replace('\n',''), 'AllHits' : allhits.replace('\n',''), 'AllProf' : allprof.replace('\n',''), 'AllBuis' : allbuis.replace('\n',''), 'AllStart' : allstart.replace('\n',''), 'AllStorm' : allstorm.replace('\n',''), 'AllSummer' : allsumm.replace('\n',''), 'AllRain' : allrain.replace('\n','') } print(json.dumps({"data": data}, indent=4))