'VsCode dropping ssh connections frequently with remote server

I'm facing a weird problem after connecting with the remote host using ssh in VSCode, the editor lost the connection after some seconds with the remote server (in this case a droplet in Digital Ocean). But when I open an ssh connection with the remote server using my local terminal instead of my local VSCode of my I do not see the same thing happen, in the terminal the connection keep alive for minutes, as expected.

Perhaps an ssh config on a remote server? I don't think so because using the terminal the problem doesn't occur.

VSCode SSH REMOTE DROPPING CONN AFTER A SOME SECONDS

So, what fix I can apply to my local VSCode configuration to stop this behaviour?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source