| Author |
Execution of script on different server
|
|
| kr.badrinath@gmail.com 2005-11-04, 8:50 pm |
| I have strange scenario could you please give suggestion to me?
Scenario
=======
I have script called try.sh on development server and I wanted to run
that script on the production server with out placing that file on the
prod server.
ie . I have to trigger the script from DEV server which inturn should
trigger it on PROD server.
Only constraint is I should not place the script on PROD server.
FYI - I have login credentials of PROD and DEV .
Please let me know how can I execute the script.
Thanks,
Badri
| |
| Helmut Kreft 2005-11-08, 6:29 pm |
| On 4 Nov 2005 16:37:21 -0800, kr.badrinath@gmail.com wrote:
>
> ie . I have to trigger the script from DEV server which inturn should
> trigger it on PROD server.
> Only constraint is I should not place the script on PROD server.
>
Strange... I suggest the following solution:
titan:~$ cat try.sh
printf "Hello world on "
hostname
titan:~$ ssh kreft@think /bin/sh < try.sh
Password:
Hello world on think
titan:~$
Helmut
--
Almost everything in life is easier to get into than out of.
(Agnes' Law)
| |
| kr.badrinath@gmail.com 2005-11-08, 6:29 pm |
| Thanks Helmut..
Is it possible to pass the password with in the script.
Instead of typing at prompt?
Thanks,
BADri
| |
| Bill Marcum 2005-11-08, 6:29 pm |
| On 6 Nov 2005 19:52:36 -0800, kr.badrinath@gmail.com
<kr.badrinath@gmail.com> wrote:
> Thanks Helmut..
>
> Is it possible to pass the password with in the script.
> Instead of typing at prompt?
>
If you use ssh, you should set up public and private keys so a password
is not needed.
--
The decision doesn't have to be logical; it was unanimous.
|
|
|
|