CyanBook
CyanBook

Reputation: 136

Looking for PyCharm Remote Dev experience similar to VS Code Remote SSH Extension

Is there anything like that? I'd like to try and maybe switch to PyCharm, but it's impossible for me without an extension like that.

Upvotes: 4

Views: 2448

Answers (1)

rernst
rernst

Reputation: 11

I know it's been a while, but I recently wanted to do this and got things working. I found this article which got me most of the way there. Basically you can update your ssh config file yourself with the needed info, just like Remote SSH does for VS Code. The one difference is that PyCharm wants the top level Host value to be something it's checks think is a valid value. So I updated it to something I know will never get used elsewhere, but also is valid.

My end input into my ssh config looks just like in that article, except I replaced the very top Host compute.x value with Host renee.local

Example:

Host renee.local
  HostName compute.<instance_id>
  IdentityFile /Users/<user_name>/.ssh/google_compute_engine
  CheckHostIP no
  HostKeyAlias compute.<instance_id>
  IdentitiesOnly yes
  StrictHostKeyChecking yes
  UserKnownHostsFile /Users/<user_name>/.ssh/google_compute_known_hosts
  ProxyCommand /Users/<user_name>/miniconda3/bin/python3 -S /Users/<user_name>/google-cloud-sdk/lib/gcloud.py beta compute start-iap-tunnel <instance_name> %p --listen-on-stdin --project=<project_name> --zone=us-central1-a --verbosity=warning
  ProxyUseFdpass no
  User <user_name>

Upvotes: 1

Related Questions