Closed jframeau closed 8 years ago
I'll have a look at it, but I'm pretty sure that self signed certificates won't work at the moment.
I didn't use that http.Client properly... There is a fix, so if you build it on your own, you could test it. Let me know if there are any further problems.
Ok, thx, nagflux works nicely with influxdb/https autosigned certificate now.
Just a little trouble when influxdb is not started:
if !s.isAlive {
s.log.Info("Waiting for InfluxDB server")
}
for i := 0; i < 12 && !s.isAlive; i++ {
s.TestIfIsAlive()
- time.Sleep(5)
+ time.Sleep(time.Duration(5) * time.Second)
s.log.Info(".")
}
Also, out of curiosity, is there a point to not use official Influxdb go client library : https://github.com/influxdata/influxdb/tree/master/client ?
Thanks for the bug fix! The Influxdb client library was still under development when I started and it changed a lot of times, so I decided to do it on my own, due to the fact there was no vendor option in go this can be very annoying.
@jframeau wondering if you can share your Connector.go file? I'm having this exact issue and can't quite figure out what changes to make.
Hi,
config:
From github, nagflux can't connect to influxdb as go http client denies access to such https connector.
I managed to add a bit of code to skip certicate check:
--- a/target/influx/Connector.go +++ b/target/influx/Connector.go @@ -1,6 +1,7 @@ package influx
import (
After that, nagflux connection went well, but nagflux failed to create the database:
2016-08-23 12:15:55 Info: good 2016-08-23 12:15:55 Info: Influxdb running 2016-08-23 12:16:05 Panic: Database does not exists and was not able to created panic: Database does not exists and was not able to created
Any idea to get https working ?
jfr