|
1 | 1 | # Dynatrace Terraform Provider
|
2 |
| -[](https://gitter.im/hashicorp-terraform/Lobby) |
3 |
| -- Terraform Website: [https://www.terraform.io](https://www.terraform.io) |
4 |
| -- Mailing list: [Google Groups](http://groups.google.com/group/terraform-tool) |
5 | 2 | ## Requirements
|
6 | 3 |
|
7 |
| -- [Terraform](https://www.terraform.io/downloads.html) 0.12+ |
| 4 | +- [Terraform](https://www.terraform.io/downloads.html) 0.13.x+ |
8 | 5 |
|
9 | 6 | ## Using the provider
|
10 | 7 |
|
11 |
| -If you want to run Terraform with the dynatrace provider plugin on your system, complete the following steps: |
12 |
| - |
13 |
| -1. [Download](https://github.com/dynatrace-oss/terraform-provider-dynatrace/releases/latest) the dynatrace provider plugin for Terraform. |
14 |
| - |
15 |
| -1. Unzip the release archive to extract the plugin binary (`terraform-provider-dynatrace_vX.Y.Z`). |
16 |
| - |
17 |
| -For Terraform version 0.12.x |
18 |
| - |
19 |
| -1. Move the binary into the Terraform [plugins directory] for the platform. |
20 |
| - - Linux/Unix/macOS: `~/.terraform.d/plugins` |
21 |
| - - Windows: `%APPDATA%\terraform.d\plugins` |
22 |
| - |
23 |
| -1. Add the plug-in provider to the Terraform configuration file. |
| 8 | +If you want to run Terraform with the dynatrace provider plugin on your system, add the plug-in provider to the Terraform configuration file. |
24 | 9 |
|
25 | 10 | ```hcl
|
26 | 11 | terraform {
|
| 12 | + required_version = "~> 0.13.0" |
27 | 13 | required_providers {
|
28 | 14 | dynatrace = {
|
29 |
| - version = "1.1.0" |
| 15 | + version = "1.2.2" |
| 16 | + source = "dynatrace.com/com/dynatrace" |
30 | 17 | }
|
31 | 18 | }
|
32 |
| - } |
| 19 | + } |
33 | 20 | ```
|
34 |
| - |
35 |
| -
|
36 |
| -For Terraform version 0.13.x |
37 | 21 |
|
38 |
| -1. Move the binary into the Terraform [plugins directory] for the platform. |
39 |
| - - Linux: `~/.terraform.d/plugins/dynatrace.com/com/dynatrace/1.0.4/linux_amd64/` |
40 |
| - - macOS: `~/.terraform.d/plugins/dynatrace.com/com/dynatrace/1.0.4/darwin_amd64/` |
41 |
| - - Windows: `%APPDATA%\terraform.d\plugins\dynatrace.com\com\dynatrace\1.0.4\windows_amd64\` |
42 |
| -
|
43 |
| -1. Add the plug-in provider to the Terraform configuration file. |
| 22 | +In order to configure the provider, add a code section like this into your Terraform configuration file |
44 | 23 |
|
45 | 24 | ```hcl
|
46 |
| - terraform { |
47 |
| - required_version = "~> 0.13.0" |
48 |
| - required_providers { |
49 |
| - dynatrace = { |
50 |
| - version = "1.1.0" |
51 |
| - source = "dynatrace.com/com/dynatrace" |
52 |
| - } |
53 |
| - } |
54 |
| - } |
| 25 | + provider "dynatrace" { |
| 26 | + dt_env_url = "https://#######.live.dynatrace.com" |
| 27 | + dt_api_token = "##########################################" |
| 28 | + } |
55 | 29 | ```
|
| 30 | +where `dt_env_url` represents the URL of your Dynatrace Environment and `dt_api_token` needs to be an API Token with the permissions `Read configuration` and `Capture request data`. |
56 | 31 |
|
57 | 32 | ## Currently supported configuration settings
|
58 | 33 | * Dashboards
|
|
0 commit comments