This repository has been archived by the owner on Jan 8, 2024. It is now read-only.
send "EOF" event for stdin through exec session when stdin is closed #830
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This adds "EOF" awareness for stdin to exec so that stdin can be
properly closed on the remote side. Without this, some processes would
hang indefinitely waiting for stdin to close. For example, if you run
cat | ls
(just normally, not via Waypoint), ls hangs forever since itis waiting for stdin to close.
For non-interactive stdout and an interactive stdin, we treat stdin as
closed. This seems to align with how other Unix tools treat stdin in
this case (such as ls).
This change requires a full client, server, entrypoint update to work,
but is backwards compatible throughout and just falls back to the same
buggy behavior.
Fixes #826