moved ssh bits out to own script