An opinionated OVHCloud Go SDK based on github.com/ovh/go-ovh
The official go-ovh is a lightweight Go wrapper around the whole OVH APIs. I wanted to create an opinionated view on a subset of features.
It is build, that it resembles the SDKs from other cloud-providers like DigitalOcean.
When using the NewOVHDefaultClient(region, serviceName string)
the client will look for following environment
variables:
OVH_ENDPOINT
,OVH_APPLICATION_KEY
,OVH_APPLICATION_SECRET
OVH_CONSUMER_KEY
If either of these parameter is not provided, it will look for a configuration file of the form:
[default]
; general configuration: default endpoint
endpoint=ovh-eu
[ovh-eu]
; configuration specific to 'ovh-eu' endpoint
application_key=my_app_key
application_secret=my_application_secret
consumer_key=my_consumer_key
Depending on the API you want to use, you may set the endpoint
to:
ovh-eu
for OVH Europe APIovh-us
for OVH US APIovh-ca
for OVH Canada APIsoyoustart-eu
for So you Start Europe APIsoyoustart-ca
for So you Start Canada APIkimsufi-eu
for Kimsufi Europe APIkimsufi-ca
for Kimsufi Canada API- Or any arbitrary URL to use in a test for example
The client will successively attempt to locate this configuration file in
- Current working directory:
./ovh.conf
- Current user's home directory
~/.ovh.conf
- System wide configuration
/etc/ovh.conf
When using NewOVHClient(endpoint, appKey, appSecret, consumerKey, region, serviceName string)
you have to provide all
the values.
Feel free to join.
Apache License, Version 2.0