Move SSH port on Ubuntu
Edit the following file:
nano /etc/ssh/sshd_config
There is a line commented out:
# Port 22
Uncomment the line by removing # and change 22 to your desired port number.
Restart the sshd service by running the following command:
service sshd restart