influxdb-client-go
influxdb-client-go copied to clipboard
SDK should use local configuration file when no ENV variables are available
Much like kubectl, aws and gcloud-cli, az-cli: env variables are the first source of credentials, but they all fall back to local credentials (using the current configured profile)
Interesting idea, @gitirabassi. However, I don't think such functionality belongs to the library. This should be incorporated into a tool that uses the library. E.g. if the influx
tool would use go client it could use env variables to feed them to the go client API.
The examples you provided are actually also tools and they internally use some libraries for connecting to the respective server.
@vlastahajek all these tools use the official sdk which has the functionality i’m asking for. This helps giving a consistent feel and usage. Using the influx tool and a custom go program on their machine should work seamesly