I tried to set up the Linux Project Wizard using Visual Studio 2022 and Visual GDB. When setup a new SSH connection I met the error of No connection could be made because the target machine refused it 127.0.1.1:22. I tried using NAT network and Bridged Adapter but it would not work either. I had also set up the ssh keys which I had put my public key in the Microsoft TFS.
This looks like a general network configuration error and not something specific to VisualGDB. Please make sure you can connect to the same VM using PuTTY or any other SSH client. Once this works, feel free to share the settings that worked and we will help you configure VisualGDB to connect to the same target.