How can I redirect SSH users to another SSH login?
Consider using a ForceCommand
directive in sshd_config
. For example, I use these to force groups of users to a set of servers:
Match Group group1
ForceCommand ssh -t group1.fqdn
Match Group="*,!local,!group2,!root"
ForceCommand ssh -t group3.fqdn
You could use:
Match User foo
ForceCommand ssh -t target-host
You thought to edit the bashrc file. I would take a look at limiting their access to all bash commands other than ssh this way they can . This link has good information.
Another thought is to setup a ssh pass through tunnel without access to a login. This link might be useful as well. This might be easier to configure.