Re: [ILUG] Running command after login.

From: Gavin McCullagh (gavin at domain fiachra.ucd.ie)
Date: Thu 27 Sep 2001 - 12:04:45 IST


On Thu, 27 Sep 2001, Liam Bedford wrote:

> On Thu, Sep 27, 2001 at 11:53:24AM +0100, Aherne Peter-pahern02 came forth with:
> > Hi,
> >
> > case 2
> > login to server2; run this2
> > etc....
> >
> any possibility of having a script like:
>
> #!/bin/sh
> command1
> command2
> exec bash -i --login

I would've expected from the things said above we'd need:

if (`uname -n` == "server1")

        command1
else

        command2
fi

Perhaps I have the wrong end of the stick here?

Gavin



This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:12:20 GMT