From d0a98d9b0ef2af50edf137a5d1c3df5399acb0ff Mon Sep 17 00:00:00 2001 From: Andreas Wrede Date: Tue, 6 Jan 2015 15:44:22 +0100 Subject: [PATCH] also listen on IPv6 --- hbd | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/hbd b/hbd index 349abf1..6efc291 100755 --- a/hbd +++ b/hbd @@ -165,13 +165,15 @@ def pushover(msg): if not SEND_PUSHOVER: return conn = httplib.HTTPSConnection("api.pushover.net:443") - conn.request("POST", "/1/messages.json", - urllib.urlencode({ - "token": "ac7NLX2rPjXFareeDgLpXNoDf4iFmf", - "user": "uDhH33UjQQDYtNzJb1ThRiWb9ingGK", - "message": msg, - }), { "Content-type": "application/x-www-form-urlencoded" }) - conn.getresponse() + try: + conn.request("POST", "/1/messages.json", + urllib.urlencode({ + "token": "ac7NLX2rPjXFareeDgLpXNoDf4iFmf", + "user": "uDhH33UjQQDYtNzJb1ThRiWb9ingGK", + "message": msg, }), { "Content-type": "application/x-www-form-urlencoded" }) + conn.getresponse() + except: + pass # nsupdate: set the DNS A record for a fqdn