Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forward the exit status from the remote command #9

Closed
kimhanse opened this issue Oct 14, 2019 · 7 comments
Closed

Forward the exit status from the remote command #9

kimhanse opened this issue Oct 14, 2019 · 7 comments

Comments

@kimhanse
Copy link

Please change the mssh command to forward the exit status of the remote command the same way ssh does.

The man page from ssh describing this:

EXIT STATUS
ssh exits with the exit status of the remote command or with 255 if an error occurred.

Example:

kim@splint:~$ mssh ec2-user@i-012345678990 exit 42 ; echo $?
0
kim@splint:~$ 

This should echo 42 instead of 0.

@jaseemabid
Copy link

+1 on this. I've scripts that wait until the server is ready and exiting with 0 breaks that kind of workflow. It would be great to get this prioritised.

@LeszekBlazewski
Copy link

I see that a fix has been already provided but the repo seems unmaintained. Are there any plans to merge this fix anytime soon ?

Would be awesome thanks !

@yellowtailfan
Copy link

yellowtailfan commented Jun 22, 2020

Getting the return code from mssh is very important for the code I'm working on, so I was happy when I found a fork with a fix:

mplaza-ptc@57ab4b5

which the author has kindly published at PyPI:

https://pypi.org/project/ec2instanceconnectcli-ptc/

@LeszekBlazewski
Copy link

LeszekBlazewski commented Jun 25, 2020 via email

@CptTZ
Copy link
Contributor

CptTZ commented Jun 25, 2020

Hi @yellowtailfan, thanks for providing this! I'm not aware of that fork, however I would recommend verifying that code before using it.

And to everyone else, sorry for the delays in keeping CLI updated. We are now actively working on releasing a new version with some improvements.

@CptTZ CptTZ closed this as completed in 0c8f851 Jun 29, 2020
@LeszekBlazewski
Copy link

Awesome that the fix has been merged !

I don't want to open new issue for this but are there any plans to release the version with fixes to PyPI in order to install it with pip ?

I guess you are working on an bigger release but is there any ETA when we can expect the new version on PyPI ?

Best regards :)

@CptTZ
Copy link
Contributor

CptTZ commented Jul 1, 2020

Awesome that the fix has been merged !

I don't want to open new issue for this but are there any plans to release the version with fixes to PyPI in order to install it with pip ?

I guess you are working on an bigger release but is there any ETA when we can expect the new version on PyPI ?

Best regards :)

We are working on the final steps now, I don't have an ETA but it should be quick. I will update here once PyPI is updated.

Thanks for the support!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants