Skip to content

Instantly share code, notes, and snippets.

@ziritrion
Created September 7, 2021 18:21
Show Gist options
  • Save ziritrion/4ad84c6aec2bee0b201db60030f559c5 to your computer and use it in GitHub Desktop.
Save ziritrion/4ad84c6aec2bee0b201db60030f559c5 to your computer and use it in GitHub Desktop.
Gcloud quick reference
  1. Start your instance from Cgloud console
  2. (Local terminal) Change to your project
    1. gcloud projects list
    2. gcloud config set project my-project
  3. Create the ssh blob for easier connection
    • gcloud compute config-ssh
  4. Inside ~/ssh/ a new config file should appear with the necessary info to connect. The host name should be enough to connect via SSH
    • ssh instance.zone.project
  5. In VSCode, with the Remote SSH extension, use the same instruction to add the necessary info in order to log into the instance. The passphrase will be asked.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment