הוספת מכשירי VCF באמצעות Terraform

בדף הזה מוסבר איך להקצות Google Cloud מאזני עומסים, כתובות IPv4 פנימיות שמורות ורשומות Cloud DNS למכשירי ניהול נוספים של VMware Cloud Foundation ‏ (VCF) ב-VMware Solution ב- Google Cloud , באמצעות מודולים של Terraform לאוטומציה מקצה לקצה (E2E).

הוספת מכשירים נוספים

כדי להוסיף מכשירי ניהול חדשים לאשכול קיים, צריך להשתמש באותה סביבת עבודה ובאותו קובץ תמונת מצב (terraform.tfstate) של Terraform שבהם השתמשתם במהלך הפריסה הראשונית של האשכול. אם המכשיר אמור להיות ברשת המשנה לניהול, מוסיפים אותו למפה mgmt_ip_values. אם הוא אמור להיות ברשת המשנה NSX TEP, מוסיפים אותו למפה nsx_ip_values.

בשלבים הבאים מוסבר איך להוסיף את מכשירי ה-IP הווירטואלי (VIP) של VCF Automation Appliance‏ (auto-vip) ו-VCF Automation Runtime‏ (auto-platform) (על סמך ההגדרה לדוגמה בקובץ e2e-terraform/sample_management_cluster.tfvars):

  1. עדכון קובץ הגדרות המשתנים (management_cluster.tfvars): מגדירים את המשתנה deployment_mode לערך "appliance_addition" ומוסיפים את הרשומות החדשות של המכשירים ישירות למפה mgmt_ip_values (או nsx_ip_values):

    deployment_mode = "appliance_addition"
    
    mgmt_ip_values = {
      # VCF Control Plane Core Services
      "sddcm"     = "10.200.0.9"              # VCF SDDC Manager Appliance
      "collector" = "10.200.0.10"             # VMware Cloud Proxy Appliance
      "vc01"      = "10.200.0.11"             # Management vCenter Server Appliance (VCSA)
      "license"   = "10.200.0.16"             # VCF License Manager Service
      "shared01"  = "10.200.0.17"             # VCF Instance Service Manager
      "vidb"      = "10.200.0.18"             # VMware Workspace ONE Access / Identity Broker
      "vsp01"     = "10.200.0.50"             # VCF Services Runtime Platform
      "vsrt"      = "10.200.0.51-10.200.0.62" # VCF Services Runtime IP Pool
    
      # VMware Aria Suite Operations & Automation Services
      "ops01"    = "10.200.0.12" # VMware Aria Operations Primary Node
      "ops02"    = "10.200.0.24" # VMware Aria Operations Replica Node
      "ops03"    = "10.200.0.25" # VMware Aria Operations Data Node
      "fleetlcm" = "10.200.0.13" # VMware Aria Operations Fleet Management Service
    
      # New appliances added in this operation
      "auto-vip"      = "10.200.0.20" # VCF Automation Appliance VIP
      "auto-platform" = "10.200.0.21" # VCF Automation Runtime
      # "auto-node"   = "10.200.0.81-10.200.0.85" # VCF Automation Cluster Node IP Pool (5 nodes)
    
      # NSX Management Cluster & Management Interfaces
      "nsx01" = "10.200.0.14" # NSX Management Cluster Floating Virtual IP (VIP)
      "nsx02" = "10.200.0.15" # NSX Manager Node 1 Management IP
      "nsx03" = "10.200.0.22" # NSX Manager Node 2 Management IP
      "nsx04" = "10.200.0.23" # NSX Manager Node 3 Management IP
    }
    
  2. יוצרים ומחילים את תוכנית הביצוע של Terraform:

    terraform plan -var-file='management_cluster.tfvars' -out=tfplan
    terraform apply tfplan
    

ההתנהגות הצפויה

כשמחילים את ההגדרות של appliance_addition, ‏Terraform מבצעת את הפעולות הבאות בלי להפריע:

  • שומר את כתובות ה-IPv4 הפנימיות הסטטיות (10.200.0.20 ו-10.200.0.21) בשביל המכשירים החדשים.
  • מקצה שירותי קצה עורפי אזוריים (vcf-mgmt-sample-auto-vip-lb ו-vcf-mgmt-sample-auto-platform-lb) שמוגדרים עם מדיניות GARP_RA להעברה מהירה של כתובות IP בזמינות גבוהה.
  • הקצאת כללי העברה אזוריים (vcf-mgmt-sample-auto-vip-fr ו-vcf-mgmt-sample-auto-platform-fr).
  • רושם רשומות להעברה (A) ורשומות הפוכות (PTR) ב-Cloud DNS.

המאמרים הבאים