-
Notifications
You must be signed in to change notification settings - Fork 7
Using University of Manchester HYDRA server
Logging into the University of Manchester HYDRA server:
ssh username@hydra.itservices.manchester.ac.ukAssuming already generated SSH keys for use with GitHub (see notes on regenerating them if needed), no need to run ssh-keygen and ssh-add to store keys in a keychain (for secure handling with ssh-agent).
- After
sshing into the server,ls ~/.ssh/authorized_keyswill show the presence of keys on the server, i.e. it supports SSH key automated logins rather than manual password each time - run
ssh-copy-id username@hydra.itservices.manchester.ac.ukto add your SSH key to the server, provide the server your password to confirm - the above
sshcommand will no longer prompt for a password, nor willscp/rsync.
Add to (local) .bashrc:
alias hydra="ssh username@hydra.itservices.manchester.ac.uk"
Logging into the HYDRA server is now just hydra
Add to (server) ~/.bashrc:
# Load tmux
if command -v tmux>/dev/null; then
if [ ! -z "$PS1" ]; then
[ -z $TMUX ] && tmux
fi
fiAdd to (server) ~/.tmux.conf:
unbind C-b
set -g prefix C-a
bind C-a send-prefix
set -g mode-mouse on
set -g mouse-resize-pane on(Assuming default Ctrl+B keybinding has not been changed) your local and server tmux instances obviously cannot share the same keybindings, meaning Ctrl + B cannot be used for using tmux on the server, Ctrl + arrow keys cannot be used for resizing its panes either. Set Ctrl + A and turn on mouse mode (to click and drag pane boundaries instead). Also requires holding Shift when highlighting text to copy (Ctrl + C).