From a3349b0769ac160a2574436316ca4849f645b900 Mon Sep 17 00:00:00 2001 From: Knut Ahlers Date: Sun, 5 Mar 2023 13:49:26 +0100 Subject: [PATCH] Use SSL in influx connection Signed-off-by: Knut Ahlers --- influx.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/influx.py b/influx.py index 22d822c..cd122fa 100644 --- a/influx.py +++ b/influx.py @@ -4,9 +4,15 @@ from influxdb import InfluxDBClient class Influx(): def __init__(self, host, port, user, password, database): - self.client = InfluxDBClient(host, port, - user, password, - database) + self.client = InfluxDBClient( + host=host, + port=port, + username=user, + password=password, + database=database, + ssl=True, + verify_ssl=True, + ) self.database = database def submit(self, body):