ianmiell / shutit

Automation framework for programmers
http://ianmiell.github.io/shutit/
MIT License
2.15k stars 110 forks source link

Cannot keep connection when logged in to remote server #316

Closed jimmytuc closed 6 years ago

jimmytuc commented 6 years ago

I'm always faced with this problem when trying to log in via bash script

screenshot at may 17 18-24-23

Have anyone solved this?

ianmiell commented 6 years ago

Looks like the default shell on the remote is a 'sh' binary, not 'bash' - is that the case?

I may be able to work around this, let me look at the code.

On Thu, May 17, 2018 at 12:27 PM, James Patrick Page < notifications@github.com> wrote:

I'm always faced with this problem when trying to log in via bash script [image: screenshot at may 17 18-24-23] https://user-images.githubusercontent.com/3124405/40174631-e9594b92-59ff-11e8-8aea-4db8de7bfc5d.png

Have anyone solved this?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ianmiell/shutit/issues/316, or mute the thread https://github.com/notifications/unsubscribe-auth/AGrczYgf3ibudiPIcjJYG_KOtC53bZqTks5tzV6rgaJpZM4UC42w .

ianmiell commented 6 years ago

Is bash installed on the host (so I can run it up if it's seen?) - it's kind of an assumption that bash is available.

Also, what's the wider use case? I'm always curious to know whether I can help achieve your goal.

On Thu, May 17, 2018 at 1:25 PM, Ian Miell ian.miell@gmail.com wrote:

Looks like the default shell on the remote is a 'sh' binary, not 'bash' - is that the case?

I may be able to work around this, let me look at the code.

On Thu, May 17, 2018 at 12:27 PM, James Patrick Page < notifications@github.com> wrote:

I'm always faced with this problem when trying to log in via bash script [image: screenshot at may 17 18-24-23] https://user-images.githubusercontent.com/3124405/40174631-e9594b92-59ff-11e8-8aea-4db8de7bfc5d.png

Have anyone solved this?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ianmiell/shutit/issues/316, or mute the thread https://github.com/notifications/unsubscribe-auth/AGrczYgf3ibudiPIcjJYG_KOtC53bZqTks5tzV6rgaJpZM4UC42w .

jimmytuc commented 6 years ago

Thanks for your responses @Ianmiell Yes, I'm using iTerm2 for mac & bash installed on the remote host

http://i.prntscr.com/CeKDoPnsSJ_4wJZc831Z-A.png

My use case is auto the deployment to multiple staging hosts whenever code committed.

Thanks for any advices.

ianmiell commented 6 years ago

Can you re-run with --debug and send me the output? Thanks.

ianmiell commented 6 years ago

I've made a small change to the code that might help and pushed, so if you pip install --upgrade can you send me the output from that?

I don't think it fully fixes, but if that does what I expect, then a fuller fix should be easy to implement.

jimmytuc commented 6 years ago

You're right, @ianmiell

I've changed the default shell to bash on the remote host. It's working now.

Many thanks.

jimmytuc commented 6 years ago

I will upgrade your latest update on it after I've done some automate tasks on shutit.

Thanks for your help.

ianmiell commented 6 years ago

James, great news, thanks. If you can give me feedback on any docs and/or ask me for help when needed that would be great. Ian

On Fri, May 18, 2018 at 12:28 PM, James Patrick Page < notifications@github.com> wrote:

I will upgrade your latest update on it after I've done some automate tasks on shutit.

Thanks for your help.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ianmiell/shutit/issues/316#issuecomment-390178525, or mute the thread https://github.com/notifications/unsubscribe-auth/AGrczf9NuuvH2b3XoJrCBH0K8l-FP51Fks5tzrBAgaJpZM4UC42w .

jimmytuc commented 6 years ago

Sure, Ian