בדף הזה מוסבר איך להתקין את Terraform ל-Cloud de Confiance ב-Cloud Shell ובמעטפת מקומית. Cloud Shell היא סביבת מעטפת אינטראקטיבית של Cloud de Confianceשמאפשרת ללמוד על Cloud de Confiance הפרויקטים והמשאבים שלכם ולנהל אותם מדפדפן האינטרנט.
מדריך למתחילים לשימוש ב-Terraform עם Cloud de Confianceזמין במאמר Terraform for Cloud de Confiance Quickstart.
Cloud Shell
כדי להשתמש בטרמינל אונליין שכבר מוגדר בו ה-CLI של gcloud, צריך להפעיל את Cloud Shell:
בחלק התחתון של הדף הזה מתחיל סשן של Cloud Shell ומופיעה הנחיה של שורת הפקודה. הסשן יופעל תוך כמה שניות.
כדי להתקין את Terraform CLI, פועלים לפי ההוראות של HashiCorp.
אתם יכולים להתאים אישית את הסביבה כדי להתקין את Terraform CLI בהפעלת הסביבה, או להתקין את הקובץ הבינארי בספריית הבית כדי שההתקנה תישמר בין סשנים.
מריצים את הפקודה הבאה כדי לוודא ש-Terraform זמין:
terraformהפלט אמור להיראות כך:
Usage: terraform [global options] <subcommand> [args] The available commands for execution are listed below. The primary workflow commands are given first, followed by less common or more advanced commands. Main commands: init Prepare your working directory for other commands validate Check whether the configuration is valid plan Show changes required by the current configuration apply Create or update infrastructure destroy Destroy previously-created infrastructureכדי להשתמש ב-Terraform עם Cloud de Confiance, צריך לוודא שהמשימות הבאות בוצעו ב- Cloud de Confiance:
- יוצרים פרויקט Cloud de Confiance או משתמשים בפרויקט קיים.
- מפעילים את החיוב ב Cloud de Confiance פרויקט.
- מפעילים ממשקי API עבור השירותיםCloud de Confiance שרוצים לעבוד איתם.
- מגדירים אימות ל-Terraform.
מעטפת מקומית
משתמשים בהוראות ההתקנה שסופקו על ידי Terraform.
מריצים את הפקודה הבאה כדי לוודא ש-Terraform זמין:
terraformהפלט אמור להיראות כך:
Usage: terraform [global options] <subcommand> [args] The available commands for execution are listed below. The primary workflow commands are given first, followed by less common or more advanced commands. Main commands: init Prepare your working directory for other commands validate Check whether the configuration is valid plan Show changes required by the current configuration apply Create or update infrastructure destroy Destroy previously-created infrastructureכדי להשתמש ב-Terraform עם Cloud de Confiance, צריך לוודא שהמשימות הבאות בוצעו ב- Cloud de Confiance:
- יוצרים פרויקט Cloud de Confiance או משתמשים בפרויקט קיים.
- מפעילים את החיוב בפרויקט. Cloud de Confiance
- מפעילים ממשקי API עבור השירותיםCloud de Confiance שרוצים לעבוד איתם.
- מגדירים אימות ל-Terraform.
המאמרים הבאים
- עוברים על המדריך למתחילים בנושא Terraform for Cloud de Confiance .
- מידע נוסף על פקודות בסיסיות ב-Terraform