I am trying to write a script that compiles an executable, runs
rsync to copy it to a remote server, and then opens an
ssh session into the server and dispatches the executable to the grid engine.
In other words, I want a script that does the following:
1. (locally) compile 2. rsync local to remote 3. (remotely) run command to dispatch
The issue I have is that compiling the executable takes a lot of time, and right now my simple bash script will first compile, then prompt my password for the rsync and again for the SSH command.
Is there a way to somehow prompt my password once, prior to the compilation step? We are not allowed to use SSH keys for security reasons.