I followed this tutorial and when I try to connect to a server I get this error:
packet_write_wait: Connection to x.x.x.x port 22: Broken pipe
From sudo journalctl -u ssh.service
I get:
Aug 14 03:16:34 my_server sshd[2280]: Accepted publickey for myuser from my_ip port my_port ssh2: RSA *********
Aug 14 03:16:34 my_server sshd[2280]: pam_unix(sshd:session): session opened for user myuser by (uid=0)
Aug 14 03:16:35 my_server sshd[2280]: pam_unix(sshd:session): session closed for user myuser
I created my user outside of the /var/www
folder and added my pc shh key to authorized_keys
on server.
ForceCommand internal-sftp
in the configuration. It restricts the connection to only use SFTP. You will not be able to SSH to such an account. – Haxiel Aug 14 '20 at 07:33