claude-home/patterns/vm-management
Cal Corum 7edb4a3a9c CLAUDE: Update VM management patterns and Tdarr operational scripts
- Update patterns/vm-management/README.md: Add comprehensive automation workflows
  - Cloud-init deployment strategies and post-install automation
  - SSH key management integration and security hardening patterns
  - Implementation workflows for new and existing VM provisioning

- Add complete VM management examples and reference documentation
  - examples/vm-management/: Proxmox automation and provisioning examples
  - reference/vm-management/: Troubleshooting guides and best practices
  - scripts/vm-management/: Operational scripts for automated VM setup

- Update reference/docker/tdarr-monitoring-configuration.md: API monitoring integration
  - Document new tdarr_monitor.py integration with existing Discord monitoring
  - Add API-based health checks and cron scheduling examples
  - Enhanced gaming scheduler integration with health verification

- Update Tdarr operational scripts with stability improvements
  - scripts/tdarr/start-tdarr-gpu-podman-clean.sh: Resource limits and CDI GPU access
  - scripts/tdarr/tdarr-schedule-manager.sh: Updated container name references
  - scripts/monitoring/tdarr-timeout-monitor.sh: Enhanced completion monitoring

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-12 12:18:43 -05:00
..
README.md CLAUDE: Update VM management patterns and Tdarr operational scripts 2025-08-12 12:18:43 -05:00

Virtual Machine Management Patterns

Automated Provisioning

  • Cloud-init deployment - Fully automated VM provisioning from first boot
  • Post-install scripts - Standardized configuration for existing VMs
  • SSH key management - Automated key deployment with emergency backup
  • Security hardening - Password auth disabled, firewall configured

VM Provisioning Strategies

Template-Based Deployment

  • Ubuntu Server templates optimized for home lab environments
  • Resource allocation sizing and planning
  • Network configuration and VLAN assignment (10.10.0.x networks)
  • Storage provisioning and disk management

Infrastructure as Code

  • Cloud-init templates for repeatable VM creation
  • Bash provisioning scripts for existing infrastructure
  • SSH key integration with existing homelab key management
  • Docker environment setup with user permissions

Lifecycle Management

  • Automated provisioning with infrastructure as code
  • Configuration management with standardized scripts
  • Snapshot management and rollback strategies
  • Scaling policies for resource optimization

Monitoring & Maintenance

  • Resource monitoring (CPU, memory, disk, network)
  • Health checks and alerting systems
  • Patch management and update strategies
  • Performance tuning and optimization

Backup & Recovery

  • VM-level backups vs application-level backups
  • Disaster recovery planning and testing
  • High availability configurations
  • Migration strategies between hosts

Implementation Workflows

  1. Create VM in Proxmox with cloud-init support
  2. Apply cloud-init template (scripts/vm-management/cloud-init-user-data.yaml)
  3. Start VM - fully automated provisioning
  4. Verify setup via SSH key authentication

Existing VM Configuration

  1. Run post-install script (scripts/vm-management/vm-post-install.sh <ip> <user>)
  2. Automated provisioning handles updates, SSH keys, Docker
  3. Security hardening applied automatically
  4. Test connectivity and verify Docker installation

Security Architecture

  • SSH key-based authentication only (passwords disabled)
  • Emergency key backup for failover access
  • User privilege separation (sudo required, docker group)
  • Automatic security updates configured
  • Network isolation ready (10.10.0.x internal network)
  • Implementation: scripts/vm-management/README.md - Complete setup guides
  • SSH Keys: patterns/networking/ssh-key-management.md - Key lifecycle management
  • Examples: examples/networking/ssh-homelab-setup.md - SSH integration patterns
  • Reference: reference/vm-management/troubleshooting.md - Common issues and solutions