Visual Studio Code Remote Development to Linux

Remote development in VSCode is a great feature recently added that allows you to develop against another computer with all the features that VSCode normally provides. Many developers prefer Linux for developing, but its lack of app compatibility can pose problems for getting other work done. With this feature, you can have a Linux virtual machine, container, or entirely separate networked computer which you remotely connect to in order to develop. I will show you how to set this up.

You will need a Linux computer running an SSH server. Most "server" versions of Linux will come preinstalled with an SSH server. If you are using a "desktop" version, you will likely need to install it yourself.

First, you will need to install the "Remote - SSH" extension. Navigate to the extensions tab, search for it, and install it.
You will now notice a new tab on the left pane, which looks like a small computer. This is where you will configure your remote machines. Open this new pane, and hover to the upper right hand corner and press the + button to add a new machine. A new prompt will come up asking for an SSH command.
Enter the command that you would normally enter to ssh into the machine. Anther prompt will come up asking where to save the SSH configuration.
The default one is fine, which will be in your user home directory. Now you should see a target appear on the remote targets pane. Click the folder button to open a new tab which connects to the remote machine.

If you use a password to login, a prompt will ask you to enter it.
At this point, you should see a green box with "SSH: hostname", indicating that you are connected remotely to the machine. Now if you select File - Open Folder, you can browse for a folder to open on the remote machine.
You can also open a new terminal which is essentially like an SSH connection, but it is built into VSCode, the same way that a terminal is provided when developing locally.
Your remote development environment should now be setup! You can now setup your VSCode environment as you normally would, including build tasks, debugging, etc. When you want to use an extension, you will have to install it remotely, even if you already installed it to your local VSCode. For example, the C++ extension must be installed remotely in order to have Intellisense.

Comments

  1. Mystino in Slot Machines - CasinoinJapan
    Mystino is a Slot Games company, located in Japan. The company offers the best quality 인카지노 casino games for players leovegas in Japan. It is operated by ミスティーノ Rikuaki

    ReplyDelete
  2. Online pokies are beloved by gamblers as a result of|as a 카지노사이트 result of} they provide the flexibility to play free of charge. Slot machines are one of many few genres that provide an opportunity to play utilizing gratis money or spins and demo versions. Those preferring playing in} for real money, they permit to win big money rapidly.

    ReplyDelete

Post a Comment