0

I currently have an alias to connect to a remote server:

alias server='ssh [email protected]'

I would like to have an alias to connect to this server, and then automatically open mysql terminal.

Currently, I connect to the server and then run:

mysql

manually.

Is there anything like:

alias serverdb='ssh [email protected] && mysql'

but to be executed on the remote server?

1 Answer 1

2

Leave off the &&. It probably will work better if you force a tty as well (the -tt below).

alias serverdb='ssh -tt [email protected] mysql'

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .