Answers for "alias pc ubuntu ssh"

1

alias pc ubuntu ssh

Method 1 - Using SSH Config File
$ vi ~/.ssh/config  # 

Host webserver
    HostName 192.168.225.22
    User sk

$ ssh webserver


Method 2 - Using Bash aliases
Open ~/.bashrc or ~/.bash_profile file:
alias webserver='ssh [email protected]'

Then, apply the changes using command:
$ source ~/.bashrc

$ webserver
Posted by: Guest on April-30-2021

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language