On 4/14/07, Amos Shapira <[EMAIL PROTECTED]> wrote:
On 13/04/07, Yehoshua (Shay) O'Hayon Suchar <[EMAIL PROTECTED]> wrote:
> Amos Shapira wrote:
>
> > On 13/04/07, *Moshe Leibovitch* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> >     It may sound too simplistic, but you can mail it to a shell alias
> >     which will run a script.
> >
> >
> > Thanks for the idea, but I can only access mail at work through Outlook.
> >
> Can't you configure your client/outlook account to automatically send a
> mail to another machine in the internal network?

I suppose I can but ssh sounds so much easier and stright-forward, without
dependence on having Outlook running all the time...


I assume you are aware of the way you run commands on the server with ssh.

Example for those who don't:

[EMAIL PROTECTED]:/$ ssh localhost "echo ssh-server-side: \$SSH_CLIENT"
ssh-server-side: 127.0.0.1 45116 22

[EMAIL PROTECTED]:/$ CLIENT_SIDE_VAR='This is simple bash interpretation'
[EMAIL PROTECTED]:/$ ssh localhost "echo $CLIENT_SIDE_VAR"
This is simple bash interpretation

[EMAIL PROTECTED]:/$ echo "STDIN redirection example" | ssh localhost "cat"
STDIN redirection example

You can also combine them all into one ssh invocation:

[EMAIL PROTECTED]:/$ echo "STDIN redirection example" | ssh localhost
"echo ssh-server-side: \$SSH_CLIENT; echo $CLIENT_SIDE_VAR; cat"
ssh-server-side: 127.0.0.1 45116 22
This is simple bash interpretation
STDIN redirection example


--Amos


Maxim.

--
Cheers,
Maxim Veksler

"Free as in Freedom" - Do u GNU ?

=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]

Reply via email to