[clug] ssh to box, run shell command, then leave shell open?

Alex Satrapa grail at goldweb.com.au
Fri Apr 15 11:52:24 MDT 2011


And of course, apologies to the CLUG list for talking about AppleScript. In had been wading through the Max OS X Admin list earlier and wasn't paying attention to the list tag.


Alex Satrapa | web.mac.com/alexsatrapa | Ph: 0407 705 332

On 15/04/2011, at 8:07, Alex Satrapa <grail at goldweb.com.au> wrote:

> All three steps can be automated. Check my blog entry at http://manicdee.livejournal.com/91750.html - make sure to read the linked articles too!
> 
> I use some "cleverly" named AppleScripts to do things like start a MySQL server in one tab, load the Django web service in a second tab, and start a shell with virtualenvironment loaded in a third tab.
> 
> Alex Satrapa | web.mac.com/alexsatrapa | Ph: 0407 705 332
> 
> On 15/04/2011, at 7:32, Carlo Hamalainen <carlo.hamalainen at gmail.com> wrote:
> 
>> Hi,
>> 
>> I often find myself doing this at work:
>> 
>> $ ssh someone at remotebox
>> $ source lots_of_dev_variables.sh
>> $ cd /projects/blah/blah/blah
>> (then I do stuff in the shell)
>> 
>> 
>> Is it possible to automate the first three steps? There are a few
>> answers on stackoverflow for this kind of question but they often
>> involve running bash at the end of the ssh command, and that stuffs up
>> environment variables
> -- 
> linux mailing list
> linux at lists.samba.org
> https://lists.samba.org/mailman/listinfo/linux


More information about the linux mailing list