mirror of
https://github.com/Schrolli91/BOSWatch.git
synced 2026-02-06 07:14:17 +01:00
little edit bosmon plugin
This commit is contained in:
parent
813fdb02f5
commit
4656fd571e
|
|
@ -39,7 +39,7 @@ def run(typ,freq,data):
|
|||
headers = {}
|
||||
headers['Content-type'] = "application/x-www-form-urlencoded"
|
||||
headers['Accept'] = "text/plain"
|
||||
if bosmon_user:
|
||||
if globals.config.get("BosMon", "bosmon_user"):
|
||||
headers['Authorization'] = "Basic {0}".format(base64.b64encode("{0}:{1}".format(globals.config.get("BosMon", "bosmon_user"), globals.config.get("BosMon", "bosmon_password"))))
|
||||
httprequest = httplib.HTTPConnection(globals.config.get("BosMon", "bosmon_server"), globals.config.get("BosMon", "bosmon_port"))
|
||||
httprequest.request("POST", "/telegramin/"+bosmon_channel+"/input.xml", params, headers)
|
||||
|
|
|
|||
Loading…
Reference in a new issue