Discover and adopt existing infrastructure - analyze Terraform structure, AWS profiles, and custom agents to generate faber-cloud configuration and migration plan
Analyzes existing Terraform, AWS profiles, and custom scripts to generate faber-cloud configuration and migration plans. Triggers when users need to migrate infrastructure management to faber-cloud, discovering their current setup without making any changes.
/plugin marketplace add fractary/claude-plugins/plugin install fractary-faber-cloud@fractaryThis skill inherits all available tools. When active, it can use any tool Claude has access to.
scripts/discover-aws-profiles.shscripts/discover-custom-agents.shscripts/discover-integration-patterns.shscripts/discover-terraform.shscripts/generate-adoption-spec.shscripts/generate-config.shscripts/generate-migration-report.shscripts/shared/assess-complexity.shscripts/shared/validate-environments.shscripts/validate-generated-config.shtemplates/config-flat-terraform.jsontemplates/config-modular-terraform.jsontemplates/config-multi-environment.jsontemplates/discovery-schemas.jsonYou discover what they have, generate appropriate configuration, and provide a clear migration path. </CONTEXT>
<CRITICAL_RULES> IMPORTANT: Discovery is Read-Only
IMPORTANT: User Guidance
Mark each step in_progress → completed as you go.
OUTPUT START MESSAGE:
🔍 STARTING: Infrastructure Discovery
Project: {project_name}
Output: {output_dir}
───────────────────────────────────────
EXECUTE STEPS:
NOTE: The adopt command discovers and analyzes existing infrastructure. It does NOT require faber-cloud to be configured yet - that's what this command will set up!
IMPORTANT: If you encounter missing files or "plugin not installed" errors, this is NORMAL. The adopt workflow will:
.fractary/plugins/faber-cloud/config.json/fractary-faber-cloud:init firstCheck project directory exists and is a valid project:
Execute Terraform discovery:
bash plugins/faber-cloud/skills/infra-adoption/scripts/discover-terraform.sh {project_root} {output_dir}/discovery-terraform.json
This discovers:
Execute AWS profiles discovery:
bash plugins/faber-cloud/skills/infra-adoption/scripts/discover-aws-profiles.sh {project_name} {output_dir}/discovery-aws.json
This discovers:
Execute custom agents discovery:
bash plugins/faber-cloud/skills/infra-adoption/scripts/discover-custom-agents.sh {project_root} {output_dir}/discovery-custom-agents.json
This discovers:
Load all three discovery reports:
Analyze combined results:
Display comprehensive summary:
═══════════════════════════════════════════════════════════
📊 DISCOVERY SUMMARY
═══════════════════════════════════════════════════════════
🏗️ TERRAFORM INFRASTRUCTURE
Structure: {flat|modular|multi-environment}
Location: {terraform_directory}
Resources: {count} defined
Backend: {local|S3|remote}
Environments: {environment_strategy}
☁️ AWS CONFIGURATION
Profiles Found: {total_profiles}
Project-Related: {project_profiles}
Environments: {detected_environments}
Naming Pattern: {pattern}
🔧 CUSTOM INFRASTRUCTURE CODE
Agents/Scripts: {file_count}
Purposes: {purposes_list}
Version Controlled: {tracked_count}/{total_count}
💡 RECOMMENDATIONS
{recommendation_1}
{recommendation_2}
...
⏱️ ESTIMATED MIGRATION TIME
{simple: 1-2 hours | moderate: 4-6 hours | complex: 1-2 days}
═══════════════════════════════════════════════════════════
Ask user:
Execute configuration generation:
bash plugins/faber-cloud/skills/infra-adoption/scripts/generate-config.sh \
{output_dir}/discovery-terraform.json \
{output_dir}/discovery-aws.json \
{output_dir}/discovery-custom-agents.json \
{output_dir}/config.json
This generates:
Execute migration report generation:
bash plugins/faber-cloud/skills/infra-adoption/scripts/generate-migration-report.sh \
{output_dir}/discovery-terraform.json \
{output_dir}/discovery-aws.json \
{output_dir}/discovery-custom-agents.json \
{output_dir}/MIGRATION.md
This generates:
Execute adoption spec generation:
bash plugins/faber-cloud/skills/infra-adoption/scripts/generate-adoption-spec.sh \
{project_root} \
{output_dir} \
{output_dir}/ADOPTION-SPEC.md
This generates a comprehensive, actionable adoption specification with:
The adoption spec is designed to be handed to another Claude Code session for immediate implementation.
Display complete adoption summary:
═══════════════════════════════════════════════════════════
📊 ADOPTION SUMMARY
═══════════════════════════════════════════════════════════
🏗️ TERRAFORM INFRASTRUCTURE
Structure: {flat|modular|multi-environment}
Location: {terraform_directory}
Resources: {count} defined
Backend: {local|S3|remote}
Environments: {environment_strategy}
☁️ AWS CONFIGURATION
Profiles Found: {total_profiles}
Project-Related: {project_profiles}
Environments: {detected_environments}
Naming Pattern: {pattern}
🔧 CUSTOM INFRASTRUCTURE CODE
Agents/Scripts: {file_count}
Purposes: {purposes_list}
Version Controlled: {tracked_count}/{total_count}
⚙️ GENERATED CONFIGURATION
Template: {flat|modular|multi-environment}
Environments: {env_count} configured
Hooks: {hook_count} suggested
Validation: Enhanced environment validation enabled
📈 COMPLEXITY ASSESSMENT
Level: {SIMPLE|MODERATE|COMPLEX}
Score: {score}/15
Estimated Migration Time: {hours} hours
⚠️ RISKS IDENTIFIED
HIGH: {high_risk_count}
MEDIUM: {medium_risk_count}
💡 KEY RECOMMENDATIONS
{recommendation_1}
{recommendation_2}
...
📋 OUTPUT FILES
- {output_dir}/discovery-terraform.json
- {output_dir}/discovery-aws.json
- {output_dir}/discovery-custom-agents.json
- {output_dir}/config.json
- {output_dir}/MIGRATION.md
- {output_dir}/ADOPTION-SPEC.md ⭐ (Detailed implementation plan)
═══════════════════════════════════════════════════════════
Ask user if they want to proceed:
❓ Ready to install faber-cloud configuration?
This will:
✓ Copy config.json to .fractary/plugins/faber-cloud/
✓ Set up directory structure
✓ Enable faber-cloud lifecycle management
You can:
1. Proceed now (recommended after review)
2. Review reports first (.fractary/adoption/)
3. Test with dry-run in test environment
Proceed with installation? (yes/no)
If dry-run mode: Skip this step, display reports only
If user approves installation:
Create target directory:
mkdir -p .fractary/plugins/faber-cloud
Copy configuration:
cp {output_dir}/config.json .fractary/plugins/faber-cloud/
Validate installation:
bash plugins/faber-cloud/skills/infra-adoption/scripts/validate-generated-config.sh \
.fractary/plugins/faber-cloud/config.json
Display success message:
✅ faber-cloud configuration installed!
Next steps:
1. Review MIGRATION.md for detailed checklist
2. Test in test environment:
/fractary-faber-cloud:audit --env=test
/fractary-faber-cloud:deploy-plan --env=test
3. Follow migration checklist step-by-step
4. Gradually roll out (test → staging → prod)
If user declines:
ℹ️ Configuration not installed
Reports saved to {output_dir}/:
- config.json (ready to install)
- MIGRATION.md (migration guide)
- discovery-*.json (discovery reports)
To install later:
1. Review the reports
2. Run /fractary-faber-cloud:adopt again
3. Or manually copy configuration
OUTPUT COMPLETION MESSAGE:
✅ COMPLETED: Infrastructure Adoption
{Installation status message}
Reports: {output_dir}/
- discovery-terraform.json
- discovery-aws.json
- discovery-custom-agents.json
- config.json
- MIGRATION.md (overview)
- ADOPTION-SPEC.md ⭐ (detailed implementation plan)
{If installed}
Configuration: .fractary/plugins/faber-cloud/config.json
Next Steps:
1. Review ADOPTION-SPEC.md for detailed implementation plan
2. Hand ADOPTION-SPEC.md to another session for implementation
3. Or follow the step-by-step guide in ADOPTION-SPEC.md yourself
The ADOPTION-SPEC.md contains:
- Complete file contents ready to create
- Command conversions with before/after code
- Full skill implementations
- Complete configuration
- Step-by-step testing instructions
───────────────────────────────────────
</WORKFLOW>
<COMPLETION_CRITERIA> ✅ All discovery scripts completed successfully ✅ Configuration generated and validated ✅ Migration report generated ✅ Comprehensive findings presented to user ✅ User confirmation obtained (or dry-run completed) ✅ Configuration installed (if approved) ✅ User has clear next steps </COMPLETION_CRITERIA>
<OUTPUTS> Return adoption summary: ```json { "status": "success", "mode": "full|dry-run", "reports": { "terraform": ".fractary/adoption/discovery-terraform.json", "aws": ".fractary/adoption/discovery-aws.json", "custom_agents": ".fractary/adoption/discovery-custom-agents.json", "configuration": ".fractary/adoption/config.json", "migration_report": ".fractary/adoption/MIGRATION.md", "adoption_spec": ".fractary/adoption/ADOPTION-SPEC.md" }, "assessment": { "infrastructure_found": true, "terraform_structure": "modular", "aws_profiles_found": 6, "custom_scripts_found": 12, "complexity": "moderate", "complexity_score": 7, "estimated_migration_hours": 12, "risks": { "high": 1, "medium": 2 } }, "configuration": { "template_used": "modular", "environments_configured": 3, "hooks_generated": 5, "installed": true }, "next_steps": [ "Review ADOPTION-SPEC.md for detailed implementation plan", "Hand ADOPTION-SPEC.md to another session for implementation", "Or follow step-by-step guide in ADOPTION-SPEC.md", "Test in test environment as spec describes" ] } ``` </OUTPUTS> <EXAMPLES> ## Example: Simple Flat StructureInput:
Output:
Structure: Flat
Complexity: Simple
Migration Time: 1-2 hours
Recommendation: Straightforward adoption, minimal configuration needed
Input:
Output:
Structure: Multi-environment with modules
Complexity: Complex
Migration Time: 1-2 days
Recommendations:
- Map custom deploy scripts to pre-deploy hooks
- Integrate audit script as standalone audit skill
- Review module dependencies carefully
</EXAMPLES>
<ERROR_HANDLING>
If Terraform discovery returns no results:
If AWS discovery returns no profiles:
If custom scripts not in git:
# Infrastructure Discovery Report
**Date:** {timestamp}
**Project:** {project_name}
## Terraform Infrastructure
- **Location:** {directory}
- **Structure:** {type}
- **Resources:** {count}
- **Backend:** {backend_type}
## AWS Configuration
- **Profiles:** {count}
- **Environments:** {env_list}
- **Pattern:** {naming_pattern}
## Custom Scripts
- **Total:** {count}
- **Purposes:** {purposes}
- **Tracked:** {tracked}/{total}
## Recommendations
{recommendations_list}
## Next Steps
1. Review this report
2. Proceed to configuration generation
3. Test with read-only operations
---
Generated by faber-cloud infra-adoption
</DOCUMENTATION>Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.