GCP gcloud CLI的gcloud compute instances list
命令可列出所有的Computer Engine instance(即VM instance)。
範例環境:
- Google Cloud SDK 417.0.1
在命令列輸入gcloud compute instances list
會顯示所有的VM instance名稱、區域及狀態等資訊。
% gcloud compute instances list
NAME ZONE MACHINE_TYPE PREEMPTIBLE INTERNAL_IP EXTERNAL_IP STATUS
demo-app asia-east1-a e2-micro 192.168.21.13 104.199.173.97 RUNNING
vm-318669d5-ed88-4236-a69b-fd23206ff135 asia-east2-a e2-micro 172.36.0.8 TERMINATED
vm-9c967207-c1b7-437c-a3f9-8630bcabfb40 asia-east2-a e2-micro 172.36.0.12 RUNNING
沒有留言:
張貼留言