Skip to content

Commit

Permalink
update example/usage docs
Browse files Browse the repository at this point in the history
  • Loading branch information
lixhunter committed Aug 5, 2024
1 parent cabf506 commit 51856b5
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 15 deletions.
6 changes: 4 additions & 2 deletions .terraform-docs.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
formatter: markdown
formatter: markdown document

settings:
anchor: false
hide-empty: true
lockfile: false

output:
Expand All @@ -14,6 +14,8 @@ sort:
content: |-
## Usage
{{ include "examples/usage/main.md" }}
```hcl
{{ include "examples/usage/main.tf" }}
```
Expand Down
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,35 +15,37 @@ Terraform Module Template
<!-- BEGIN_TF_DOCS -->
## Usage

This example demonstrates the usage of this Terraform module with default settings.

```hcl
module "terraform_module_example" {
source = "cloudeteer/terraform-module-example/azurerm"
}
```

## Providers

No providers.

## Modules

No modules.

## Resources

No resources.

## Inputs
## Required Inputs

The following input variables are required:

### <a name="input_example_variable"></a> [example\_variable](#input\_example\_variable)

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| example\_variable | Example variable (between 3 and 13 characters) | `string` | n/a | yes |
Description: Example variable (between 3 and 13 characters)

Type: `string`

## Outputs

| Name | Description |
|------|-------------|
| example\_output | n/a |
The following outputs are exported:

### <a name="output_example_output"></a> [example\_output](#output\_example\_output)

Description: n/a
<!-- END_TF_DOCS -->

## Contributions
Expand Down
34 changes: 34 additions & 0 deletions examples/usage/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Example: Usage

This primary usage example is also included in the [README.md](../../README.md) of this module.

## Prerequisites

Before you begin, ensure you have the following:

- [Terraform](https://www.terraform.io/downloads.html) installed on your local machine.
- An [Azure account](https://azure.microsoft.com/en-us/free/) with the appropriate permissions.
- [Azure CLI](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli) installed and authenticated.

## Steps to Deploy

1. **Initialize the Terraform Configuration**

Initialize the Terraform configuration to download the necessary providers and modules.

```shell
terraform init
```

2. **Apply the Terraform Configuration**

Apply the configuration to create the resources defined in your Terraform files.

```shell
terraform apply
```

## Additional Resources

- [Terraform Azure Provider Documentation](https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs)
- [Terraform Configuration Language](https://www.terraform.io/docs/language/index.html)
1 change: 1 addition & 0 deletions examples/usage/main.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This example demonstrates the usage of this Terraform module with default settings.

0 comments on commit 51856b5

Please sign in to comment.