ssh run command only

If you have to ssh to a remote server just to run
a command and log out

Syntax:
ssh remote_host_name_ip "command to run"

Example:

ssh discource "apt update && apt upgrade -y"