Skip to content

Commit e7ebd61

Browse files
authored
Merge pull request #14 from vmware-tanzu/vasundharas/templating
Refining the documentation
2 parents d080507 + 2628448 commit e7ebd61

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1963
-460
lines changed

Makefile

+7
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,13 @@ vet:
2525
lint: gofmt
2626
golangci-lint run -c ./.golangci.yml ./internal/... .
2727

28+
set-tf-acc:
29+
@echo Setting Acceptance test env variable
30+
export TF_ACC=true;\
31+
echo $$TF_ACC
32+
33+
acc-test: set-tf-acc test
34+
2835
website-lint:
2936
@echo "==> Checking website against linters..."
3037
@misspell -error -source=text website/ || (echo; \

README.md

+13-13
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
# Terraform Tanzu TMC Provider
1+
# Terraform VMware Tanzu Mission Control Provider
22

3-
This is the repository for the Terraform Tanzu TMC Provider, which one can use with
4-
Terraform to work with [VMware Tanzu TMC][vmware-tanzu-tmc].
3+
This is the repository for the Terraform Tanzu Mission Control Provider, which one can use with Terraform to work with
4+
[VMware Tanzu Mission Control][vmware-tanzu-tmc].
55

66
[vmware-tanzu-tmc]: https://tanzu.vmware.com/mission-control
77

@@ -27,8 +27,8 @@ provider "tmc" {
2727
}
2828
```
2929

30-
Version locking uses a pessimistic operator, so this version lock would mean
31-
anything within the 1.x namespace, including or after 1.0.0. [Read more][provider-vc] on provider version control.
30+
Version locking uses a pessimistic operator, so this version lock would mean anything within the 1.x namespace, including or after 1.0.0.
31+
[Read more][provider-vc] on provider version control.
3232

3333
[provider-vc]: https://docs.vmware.com/en/VMware-Tanzu-Mission-Control/index.html
3434

@@ -86,34 +86,34 @@ provider.
8686
**Flattening and Helper Tests:** These can be run by `make test` directly.
8787

8888
**Acceptance Tests:** Set the environment variables in your IDE configurations or Terminal.
89-
Environment variables that are required to be set universally are `TMC_ENDPOINT`, `TMC_CSP_ENDPOINT`, `TMC_CSP_TOKEN` and `TF_ACC`. `TF_ACC` has to be set as `true`.
89+
Environment variables that are required to be set universally are `TMC_ENDPOINT`, `TMC_CSP_ENDPOINT` and `TMC_CSP_TOKEN`.
9090

9191
Environment variables specific to particular resources:
9292

9393
- **Attach Cluster with Kubeconfig and Namespace Resource** - `KUBECONFIG`
9494
- **TKGs workload cluster** - `MANAGEMENT_CLUSTER`, `PROVISIONER_NAME`, `VERSION` and `STORAGE_CLASS`.
9595
- **TKGm Vsphere workload cluster** - `MANAGEMENT_CLUSTER` and `CONTROL_PLANE_ENDPOINT`.
9696

97-
After the environment variables are set, run the respective tests.
97+
After the environment variables are set, run `make acc-test`.
9898

9999
## Provider Documentation
100100

101-
TMC Terraform provider documentation is autogenerated using [tfplugindocs][tfplugindocs-link].
101+
Tanzu Mission Control Terraform provider documentation is autogenerated using [tfplugindocs][tfplugindocs-link].
102102

103-
Use the tfplugindocs tool to automatically generate documentation for your provider in the format required by the Terraform Registry.
103+
Use the tfplugindocs tool to generate documentation for your provider in the format required by the Terraform Registry.
104104
The plugin will read the descriptions and schema of each resource and data source in your provider and generate the relevant Markdown files for you.
105105

106106
[tfplugindocs-link]: https://github.com/hashicorp/terraform-plugin-docs
107-
## Utilising TMC provider
107+
## Using Tanzu Mission Control Provider
108108

109-
Please refer to `examples` folder to perform CRUD operations with TMC provider for various resources
109+
Please refer to `examples` folder to perform CRUD operations with Tanzu Mission Control provider for various resources
110110

111111
# Support
112112

113-
The TMC Terraform provider is now VMware supported as well as community supported. For bugs and feature requests please open a Github Issue and label it appropriately or contact VMware support.
113+
The Tanzu Mission Control Terraform provider is now VMware supported as well as community supported. For bugs and feature requests please open a Github Issue and label it appropriately or contact VMware support.
114114

115115
# License
116116

117117
Copyright © 2015-2021 VMware, Inc. All Rights Reserved.
118118

119-
The TMC Terraform provider is available under [MPL2.0 license](https://github.com/vmware-tanzu/terraform-provider-tanzu-mission-control/blob/main/LICENSE).
119+
The Tanzu Mission Control Terraform provider is available under [MPL2.0 license](https://github.com/vmware-tanzu/terraform-provider-tanzu-mission-control/blob/main/LICENSE).

docs/data-sources/tmc_cluster.md

+6-10
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
---
2-
# generated by https://github.com/hashicorp/terraform-plugin-docs
3-
page_title: "tmc_cluster Data Source - terraform-provider-tanzu-mission-control"
4-
subcategory: ""
5-
description: |-
6-
2+
Title: "Cluster Resource"
3+
Description: |-
4+
Reading the cluster resource.
75
---
86

9-
# tmc_cluster (Data Source)
10-
7+
# Cluster
118

9+
Different flavours such as attach cluster, TKG service workload and TKG Vsphere workload clusters can be fetched.
1210

1311
## Example Usage
1412

@@ -360,6 +358,4 @@ Optional:
360358

361359
- **cpu** (String)
362360
- **disk_size** (String)
363-
- **memory** (String)
364-
365-
361+
- **memory** (String)

docs/data-sources/tmc_cluster_group.md

+6-10
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
---
2-
# generated by https://github.com/hashicorp/terraform-plugin-docs
3-
page_title: "tmc_cluster_group Data Source - terraform-provider-tanzu-mission-control"
4-
subcategory: ""
5-
description: |-
6-
2+
Title: "Cluster Group Resource"
3+
Description: |-
4+
Fetching the cluster group resource to a cluster.
75
---
86

9-
# tmc_cluster_group (Data Source)
10-
7+
# Cluster Group
118

9+
A cluster group is needed for a cluster
1210

1311
## Example Usage
1412

@@ -43,6 +41,4 @@ Read-Only:
4341

4442
- **annotations** (Map of String) Annotations for the resource
4543
- **resource_version** (String) Resource version of the resource
46-
- **uid** (String) UID of the resource
47-
48-
44+
- **uid** (String) UID of the resource

docs/data-sources/tmc_cluster_node_pool.md

+16-10
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
11
---
2-
# generated by https://github.com/hashicorp/terraform-plugin-docs
3-
page_title: "tmc_cluster_node_pool Data Source - terraform-provider-tanzu-mission-control"
4-
subcategory: ""
5-
description: |-
6-
2+
Title: "Nodepool Resource"
3+
Description: |-
4+
Fetching the details of nodepool resource.
75
---
86

9-
# tmc_cluster_node_pool (Data Source)
10-
7+
# Nodepool
118

9+
A nodepool can be read.
1210

11+
## Example Usage
1312

13+
```terraform
14+
# Read TMC cluster nodepool : fetch cluster nodepool details
15+
data "tmc_cluster_node_pool" "read_node_pool" {
16+
management_cluster_name = "tkgs-terraform"
17+
provisioner_name = "test-gc-e2e-demo-ns"
18+
cluster_name = "tkgs-test"
19+
name = "default-nodepool"
20+
}
21+
```
1422

1523
<!-- schema generated by tfplugindocs -->
1624
## Schema
@@ -63,6 +71,4 @@ Optional:
6371
Optional:
6472

6573
- **class** (String) Nodepool instance type
66-
- **storage_class** (String) Storage Class to be used for storage of the disks which store the root filesystem of the nodes
67-
68-
74+
- **storage_class** (String) Storage Class to be used for storage of the disks which store the root filesystem of the nodes

docs/data-sources/tmc_namespace.md

+6-10
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
---
2-
# generated by https://github.com/hashicorp/terraform-plugin-docs
3-
page_title: "tmc_namespace Data Source - terraform-provider-tanzu-mission-control"
4-
subcategory: ""
5-
description: |-
6-
2+
Title: "Namespace Resource"
3+
Description: |-
4+
Fetching the details of namespace resource.
75
---
86

9-
# tmc_namespace (Data Source)
10-
7+
# Namespace
118

9+
A namespace can be read.
1210

1311
## Example Usage
1412

@@ -63,6 +61,4 @@ Read-Only:
6361
Optional:
6462

6563
- **attach** (Boolean)
66-
- **workspace_name** (String)
67-
68-
64+
- **workspace_name** (String)

docs/data-sources/tmc_workspace.md

+6-10
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
---
2-
# generated by https://github.com/hashicorp/terraform-plugin-docs
3-
page_title: "tmc_workspace Data Source - terraform-provider-tanzu-mission-control"
4-
subcategory: ""
5-
description: |-
6-
2+
Title: "Workspace Resource"
3+
Description: |-
4+
fetching the details of workspace resource.
75
---
86

9-
# tmc_workspace (Data Source)
10-
7+
# Workspace
118

9+
A workspace can be read.
1210

1311
## Example Usage
1412

@@ -43,6 +41,4 @@ Read-Only:
4341

4442
- **annotations** (Map of String) Annotations for the resource
4543
- **resource_version** (String) Resource version of the resource
46-
- **uid** (String) UID of the resource
47-
48-
44+
- **uid** (String) UID of the resource

0 commit comments

Comments
 (0)