Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Backport of send "EOF" event for stdin through exec session when stdin is closed into release/0.1.x #836

Conversation

hc-waypoint-bot
Copy link

Backport

This PR is auto-generated from #830 to be assessed for backporting due to the inclusion of the label backport/0.1.x.

WARNING automatic cherry-pick of commits failed. Commits will require human attention.

The below text is copied from the body of the original PR.


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 it
is 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

@hashicorp-cla
Copy link

CLA assistant check

Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement

Learn more about why HashiCorp requires a CLA and what the CLA includes


temp seems not to be a GitHub user.
You need a GitHub account to be able to sign the CLA. If you already have a GitHub account, please add the email address used for this commit to your account.

Have you signed the CLA already but the status is still pending? Recheck it.

@mitchellh mitchellh closed this Nov 20, 2020
@mitchellh mitchellh deleted the backport/b-exec-no-tty/promptly-sunny-peacock branch November 20, 2020 01:03
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants