0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

【GCP】Cloud ShellからVMインスタンスを作成してみました

Posted at

はじめに

GCPのCloud Shellは便利しすぎて、今回はCloud Shellコマンドから、インスタンスを作成してみました。

インスタンス情報

・インスタンス台数:2台(test01 test02)
・インスタンスタイプ:e2-micro
・インスタンス価格タイプ:プリエンプティブル VM インスタンス(preemptible)
・ゾーン:us-east1-b

インスタンス作成

GCPのCloud Shellを開き、以下のコマンドをたたきました。

$ gcloud compute instances create test01 test02 --project=planning-and-xxx-xxxxxxxxx --zone=us-east1-b --machine-type=e2-micro --preemptible
Created [https://www.googleapis.com/compute/v1/projects/planning-and-xxx-xxxxxxxxx/zones/us-east1-b/instances/test01].
Created [https://www.googleapis.com/compute/v1/projects/planning-and-xxx-xxxxxxxxx/zones/us-east1-b/instances/test02].
NAME: test01
ZONE: us-east1-b
MACHINE_TYPE: e2-micro
PREEMPTIBLE: true
INTERNAL_IP: 10.142.0.5
EXTERNAL_IP: xx.xx.xx.xx
STATUS: RUNNING

NAME: test02
ZONE: us-east1-b
MACHINE_TYPE: e2-micro
PREEMPTIBLE: true
INTERNAL_IP: 10.142.0.6
EXTERNAL_IP: xx.xx.xx.xx
STATUS: RUNNING

すると、GCPコンソール画面から、上記2台のインスタンスが作成されたことを確認できました。
image.png

参考資料

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?