-
Notifications
You must be signed in to change notification settings - Fork 1
/
cluster.md.tmpl
51 lines (36 loc) · 1.88 KB
/
cluster.md.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "{{.Name}} {{.Type}} - {{.ProviderName}}"
subcategory: ""
description: |-
{{ .Description | plainmarkdown | trimspace | prefixlines " " }}
---
# {{.Name}} ({{.Type}})
{{ .Description | trimspace }}
{{ if .HasExample -}}
## Example Usage (Basic)
{{ tffile "./examples/resources/akp_cluster/basic.tf" }}
- The `instance_id` assumes you have an `akp_instance` resource named `argocd`.
- The `kube_config` assumes you have a resource named `cluster.my-cluster` that provides the `host`, `token`, `client_certificate`, `client_key`, `cluster_ca_certificate` of the Kubernetes cluster to deploy the agent into.
For a complete working example using a GKE cluster, see [akuity/examples](https://github.com/akuity/examples/tree/main/terraform/akuity).
## Example Usage (Custom agent size)
{{ tffile "./examples/resources/akp_cluster/custom_agent_size.tf" }}
## Example Usage (Auto agent size)
{{ tffile "./examples/resources/akp_cluster/auto_agent_size.tf" }}
- This example uses the `auto` agent size, which will automatically scale the agent based on the number of applications in the cluster. `auto_upgrade_disabled` cannot be set to `true` when using `auto` agent size.
## Example Usage (Exhaustive)
{{ tffile "./examples/resources/akp_cluster/resource.tf" }}
{{- end }}
{{ .SchemaMarkdown | trimspace }}
## Import
In Terraform v1.5.0 and later, use an [`import` block](https://developer.hashicorp.com/terraform/language/import) to import the AKP cluster using `instance_id` and `name` separated by a forward slash (`/`). For example:
```terraform
import {
to = akp_cluster.example
id = "6pzhawvy4echbd8x/test-cluster"
}
```
Using `terraform import`, import AKP cluster using `instance_id` and `name` separated by a forward slash (`/`). For example:
```shell
terraform import akp_cluster.example 6pzhawvy4echbd8x/test-cluster
```