write_resource_file
Creates or updates Terraform resource files like main.tf and variables.tf within a module directory. Updates to outputs.tf are handled separately.
Instructions
Writes a Terraform resource file (main.tf, variables.tf, etc.) to a module directory.
Does NOT allow writing output(s).tf here. To update outputs.tf, use write_outputs().
Args: module_path (str): Path to the module directory. file_name (str): Name of the file to write (e.g., "main.tf", "variables.tf"). content (str): Content to write to the file.
Returns: str: JSON string with success, message, instructions, and optional error/data fields.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| module_path | Yes | ||
| file_name | Yes | ||
| content | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |