docs(azure-mi): update docs and added examples#901
docs(azure-mi): update docs and added examples#901pablosanchezpaz wants to merge 2 commits intomainfrom
Conversation
|
Related to #786 |
There was a problem hiding this comment.
Pull request overview
Updates the Azure Managed Identity module documentation by introducing terraform-docs header/footer injection and adding a basic example for consumers.
Changes:
- Added terraform-docs configuration with custom header/footer templates.
- Reworked
README.mdstructure to include overview, examples, and autogenerated docs sections. - Added a “basic” example (Terraform + values YAML) for the module.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| modules/azure-mi/docs/header.md | Adds a custom header with overview + usage examples to be injected by terraform-docs. |
| modules/azure-mi/docs/footer.md | Adds examples/support links footer to be injected by terraform-docs. |
| modules/azure-mi/_examples/basic/values.yaml | Provides a basic YAML values example for the module. |
| modules/azure-mi/_examples/basic/main.tf | Provides a basic Terraform example using the module. |
| modules/azure-mi/README.md | Switches to terraform-docs injected format and expands human-friendly overview/examples. |
| modules/azure-mi/.terraform-docs.yml | Configures terraform-docs injection and formatting for this module’s README. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ### YAML | ||
| ```yaml | ||
| name: xxx | ||
| resource_group_name: xxx |
There was a problem hiding this comment.
The YAML example uses resource_group_name, but the module input (and other examples in this PR) use resource_group. This inconsistency will confuse users and can lead to copy/paste misconfiguration. Rename resource_group_name to resource_group in the YAML example.
| resource_group_name: xxx | |
| resource_group: xxx |
| ### YAML | ||
| ```yaml | ||
| name: xxx | ||
| resource_group_name: xxx |
There was a problem hiding this comment.
The README YAML example uses resource_group_name, but the documented input name is resource_group (see Inputs table). Update the YAML example to use resource_group to match the actual module interface.
| resource_group_name: xxx | |
| resource_group: xxx |
| ## Outputs | ||
|
|
||
| | Name | Description | | ||
| |------|-------------| | ||
| | <a name="output_user_assigned_identity_id"></a> [user_assigned_identity_id](#output\_user\_assigned\_identity\_id) | The ID of the User Assigned Identity. | | ||
| | <a name="output\_user\_assigned\_identity\_id"></a> [user\_assigned\_identity\_id](#output\\_user\\_assigned\\_identity\\_id) | The ID of the User Assigned Identity. | |
There was a problem hiding this comment.
This manual Outputs section in the header conflicts with the terraform-docs autogenerated Outputs section later in the README (which lists id). Keeping both will drift over time and is already inconsistent. Prefer removing the manual Outputs section from the custom header (or make it match the actual output names), and rely on terraform-docs for Outputs rendering.
|
|
||
| | Name | Description | | ||
| |------|-------------| | ||
| | <a name="output_id"></a> [id](#output\_id) | # OUTPUTS SECTION User Assigned Identity | |
There was a problem hiding this comment.
The output description # OUTPUTS SECTION User Assigned Identity is not a useful consumer-facing description and reads like a placeholder. Update the output description in the module’s outputs.tf (so terraform-docs renders it correctly) to something like: 'The ID of the User Assigned Identity.'
| | <a name="output_id"></a> [id](#output\_id) | # OUTPUTS SECTION User Assigned Identity | | |
| | <a name="output_id"></a> [id](#output\_id) | The ID of the User Assigned Identity. | |
No description provided.