Login shell script

Latest response

This is the first time I have posted here so forgive me if this is not the correct place to post a question like this.
If I wanted a script to launch every time I SSH/logged into a server, where would I put it?
Here's the scenario:

Server1 - On secured network1, accessible by Server2 & Server3; not accessible by Workstation1
Server2 - On secured network1, accessible by Server1 & Server3; not accessible by Workstation1
Server3 - On secured network2, accessible by Server1, Server2 & Workstation1
Workstation1 - On unsecured network3

Server1 & Server2 are my destination servers, via SSH, from Workstation1. However, I have to use Server3 to get to Server1 & Server2; Server3 is kind of like a jump server to get from Workstation1. Every time I SSH to Server3, I would like the login script to launch. What I plan on putting in this script is the option to ask me, as soon as I login, if I I want to connect (SSH) to one of the servers and, depending on my reply, I would then either not SSH to one of the servers and just continue working on Server3 or SSH to one of the servers that I choose.
Thanks.

Responses