Add port to Slack connection when used with Mattermost

This commit is contained in:
JonnyWong16 2017-01-30 19:18:29 -08:00
parent 4dce0ec015
commit e34472084c

View file

@ -2534,9 +2534,10 @@ class SLACK(Notifier):
data['attachments'] = [attachment] data['attachments'] = [attachment]
host = urlparse(self.config['hook']).hostname host = urlparse(self.config['hook']).hostname
port = urlparse(self.config['hook']).port
path = urlparse(self.config['hook']).path path = urlparse(self.config['hook']).path
http_handler = HTTPSConnection(host) http_handler = HTTPSConnection(host, port)
http_handler.request("POST", http_handler.request("POST",
path, path,
headers={'Content-type': "application/json"}, headers={'Content-type': "application/json"},