Blenra LogoBlenra
Optimized for: Gemini / ChatGPT / Claude
#Terraform

Advanced AI Prompt for Automated Bulk Terraform Resource Import

Customize the variables below to instantly engineer your prompt.

Required Variables

advanced-automated-terraform-import-strategy.txt
Act as a Technical Migration Specialist. Write an advanced Python automation script designed to mass-import legacy infrastructure into Terraform state. The script must iterate through a comma-separated list of [RESOURCE_IDS] for the specific [RESOURCE_TYPE] (e.g., `aws_instance` or `aws_s3_bucket`) and dynamically construct and execute the required `terraform import [TARGET_MODULE].name[idx] [id]` shell commands. Furthermore, provide a conceptual strategy leveraging the new Terraform 1.5+ `import {}` block functionality to generate the missing HCL resource skeletons. Address the critical engineering challenge of reconciling complex, read-only API attributes that populate the state file against the required declarative HCL arguments so that the subsequent `terraform plan` results in zero infrastructure changes.

Example Text Output

"The AI would provide a Python automation script for generating shell commands and a corresponding set of HCL resource skeletons to match the existing infrastructure."

More Cloud & DevOps Prompts

View all →

Frequently Asked Questions

What is the "Advanced AI Prompt for Automated Bulk Terraform Resource Import" prompt used for?

The AI would provide a Python automation script for generating shell commands and a corresponding set of HCL resource skeletons to match the existing infrastructure.

Which AI tools work with this prompt?

This prompt is optimized for Gemini / ChatGPT / Claude, but works great with ChatGPT, Claude, Gemini, and other large language models. Simply copy it and paste it into your preferred AI tool.

How do I customize this prompt?

Use the variable fields above to fill in your specific details. The prompt will auto-update as you type, ready to copy instantly.

Is this prompt free?

Yes! All prompts on Blenra are free to copy and use immediately. No account required.