You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: website/docs/index.html.markdown
+14-19
Original file line number
Diff line number
Diff line change
@@ -8,32 +8,21 @@ description: |-
8
8
9
9
# OVH Provider
10
10
11
-
The OVH provider is used to interact with the
12
-
many resources supported by OVH. The provider needs to be configured
13
-
with the proper credentials before it can be used.
11
+
The OVH provider is used to interact with the many resources supported by OVH.
12
+
The provider needs to be configured with the proper credentials before it can be used.
14
13
15
14
Use the navigation to the left to read about the available resources.
16
15
17
16
## Configuration of the provider
18
17
19
-
Requests to OVH APIs need to configure secrets keys in the provider, either fetching them from `~/.ovh.conf` file, in configuration of OVH provider or from your environment.
18
+
Requests to OVH APIs require a set of secrets keys and the definition of the API end point.
19
+
See [First Steps with the API](https://docs.ovh.com/gb/en/customer/first-steps-with-ovh-api/) (or the French version, [Premiers pas avec les API OVHcloud](https://docs.ovh.com/fr/api/api-premiers-pas/)) for a detailed explanation.
20
20
21
-
It is recommend to install [ovh-cli](https://github.com/ovh/ovh-cli) to handle and manage all your secret keys.
21
+
Besides the API end-point, the required keys are the `application_key`, the `application_secret`, and the `consumer_key`.
22
+
These keys can be generated via the [OVH token generation page](https://api.ovh.com/createToken/?GET=/*&POST=/*&PUT=/*&DELETE=/*).
22
23
23
-
Follow [installation](https://github.com/ovh/ovh-cli#installation) then [setup](https://github.com/ovh/ovh-cli#getting-started) steps of ovh-cli to initialize your environment (secret keys and `~/.ovh.conf` file).
24
+
These parameters can be configured directly in the provider block as shown hereafter.
24
25
25
-
Then, you can just declare a minimal configuration of the OVH provider:
26
-
27
-
```hcl
28
-
# Configure the OVH Provider
29
-
provider "ovh" {
30
-
endpoint = "ovh-eu"
31
-
}
32
-
```
33
-
Secret keys `endpoint`, `application_key`, `application_secret` or
34
-
`consumer_key` will be fetched from the `~/.ovh.conf` file.
35
-
36
-
Or you can declare them in provider configuration:
37
26
38
27
```hcl
39
28
# Configure the OVH Provider
@@ -45,7 +34,13 @@ provider "ovh" {
45
34
}
46
35
```
47
36
48
-
Or let the provider fetching them from your environment (see "[Configuration reference](#configuration-reference)").
37
+
Alternatively the secret keys can be retrieved from your environment.
38
+
39
+
*`OVH_APPLICATION_KEY`
40
+
*`OVH_APPLICATION_SECRET`
41
+
*`OVH_CONSUMER_KEY`
42
+
43
+
This later method (or a similar alternative) is recommended to avoid storing secret data in a source repository.
0 commit comments