Shunya Ueta

How to connect the Google Compute Engine via Visual Studio Code

1. Generate SSH config file using gcloud command line

gcloud compute config-ssh

https://cloud.google.com/sdk/gcloud/reference/compute/config-ssh

You cant get ssh config for your Google Compute Engine project!

Notice: you need choose target GCP project before run below command.

gcloud config set project <your-project-id>

2. Install Remote SSH extention in Visual Studio Code.

https://code.visualstudio.com/blogs/2019/07/25/remote-ssh

3. Press ⇧⌘P & Select target connection in Visual Studio Code!

Finaly you can connect in Visual Studio Code. Welcome to VS code when you write the code in SSH connection.

---

関連しているかもしれない記事


📮 📧 🐏: 記事への感想のおたよりをおまちしてます。 お気軽にお送りください。 メールアドレス入力があればメールで返信させていただきます。 もちろんお返事を希望せずに単なる感想だけでも大歓迎です。

このサイトの更新情報をRSSで配信しています。 お好きなフィードリーダーで購読してみてください。

このウェブサイトの運営や著者の活動を支援していただける方を募集しています。 もしよろしければ、Buy Me a Coffee からサポート(投げ銭)していただけると、著者の活動のモチベーションに繋がります✨

#gcp #vscode