Skip to content

docs(azure-disks-backup): update docs and added examples#906

Draft
pablosanchezpaz wants to merge 3 commits intomainfrom
add/azure-disks-backup-docs
Draft

docs(azure-disks-backup): update docs and added examples#906
pablosanchezpaz wants to merge 3 commits intomainfrom
add/azure-disks-backup-docs

Conversation

@pablosanchezpaz
Copy link
Contributor

No description provided.

@pablosanchezpaz pablosanchezpaz requested a review from a team as a code owner February 6, 2026 08:27
@pablosanchezpaz
Copy link
Contributor Author

Related to #786

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the azure-disks-backup module documentation and adds runnable examples, with terraform-docs configuration to generate/maintain the README.

Changes:

  • Added docs/header.md and docs/footer.md and switched README to terraform-docs injected content.
  • Added a basic example (_examples/basic) with both main.tf and values.yaml.
  • Added .terraform-docs.yml to standardize README generation.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
modules/azure-disks-backup/docs/header.md New header content used by terraform-docs, including overview + HCL example.
modules/azure-disks-backup/docs/footer.md New footer content used by terraform-docs (links + support info).
modules/azure-disks-backup/_examples/basic/values.yaml New YAML values example for the module.
modules/azure-disks-backup/_examples/basic/main.tf New minimal Terraform example wiring the module.
modules/azure-disks-backup/README.md Converted to terraform-docs injected README; expanded overview/example/notes and generated tables.
modules/azure-disks-backup/.terraform-docs.yml Added terraform-docs config to inject header/footer and generate README.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

## Overview

This Terraform module allows you to create and configure managed disks backups in Azure, including:
- Creation of Recovery Services vault.
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The module resources referenced elsewhere are azurerm_data_protection_backup_vault (Data Protection Backup Vault), not a Recovery Services vault. To avoid misleading users, rename this to “Data Protection Backup Vault” (or “Azure Data Protection backup vault”) so the terminology matches the actual Azure service/provider resources.

Suggested change
- Creation of Recovery Services vault.
- Creation of an Azure Data Protection backup vault.

Copilot uses AI. Check for mistakes.

This module creates and configures Azure Backup for managed disks. It sets up a Recovery Services vault, backup policies, and backup instances for specified disks.
This Terraform module allows you to create and configure managed disks backups in Azure, including:
- Creation of Recovery Services vault.
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same terminology issue as in docs/header.md: this appears to be a Data Protection Backup Vault module (azurerm_data_protection_backup_vault), not Recovery Services Vault. Updating this wording will prevent confusion for users trying to map docs to Azure Portal/services.

Suggested change
- Creation of Recovery Services vault.
- Creation of a Data Protection Backup vault.

Copilot uses AI. Check for mistakes.
Comment on lines 68 to 74
backup_instances = [
{
# Name of the disk to be backed up
disk_name = "foo-disk"

# Resource group where the disk is located
disk_resource_group = "foo-data"

# Resource group where the snapshot will be stored
snapshot_resource_group_name = "bk-disks"

# Name of the backup policy to apply
backup_policy_name = "foo-policy"
disk_name = "foo-disk"
disk_resource_group = "foo-data"
snapshot_resource_group_name = "bk-disks"
backup_policy_name = "foo-policy"
},
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The example includes snapshot_resource_group_name, but the generated Inputs table below defines backup_instances without that field (and the _examples/basic/values.yaml also omits it). Please make the README consistent: either remove snapshot_resource_group_name from the example if the module no longer accepts it, or update the module input schema/docs so it’s documented and shown in the inputs table.

Copilot uses AI. Check for mistakes.
Comment on lines +18 to +20
name = "foo-policy"
backup_repeating_time_intervals = ["R/2024-10-17T11:29:40+00:00/PT1H"]
default_retention_duration = "P7D"
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The example hard-codes a specific start timestamp for backup_repeating_time_intervals in 2024. As time passes, this can become stale and may be rejected by the Azure API/provider if it requires a start time in the present/future. Consider using a placeholder in docs (e.g., R/<RFC3339_START>/PT1H) and explaining it, or generating the start time dynamically (if supported by the module/provider).

Copilot uses AI. Check for mistakes.
- `vault_id`: The ID of the Recovery Services vault
| Name | Description |
|------|-------------|
| <a name="output_vault_id"></a> [vault\_id](#output\_vault\_id) | n/a |
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generated outputs table shows vault_id with description n/a, which typically means the output block lacks a description. Adding an output description in outputs.tf and regenerating docs would make the README more informative for consumers.

Suggested change
| <a name="output_vault_id"></a> [vault\_id](#output\_vault\_id) | n/a |
| <a name="output_vault_id"></a> [vault\_id](#output\_vault\_id) | The resource ID of the backup vault created by this module. |

Copilot uses AI. Check for mistakes.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@pablosanchezpaz pablosanchezpaz marked this pull request as draft February 11, 2026 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants