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

enable handle_run to accept io redirect paths #342

Merged
merged 1 commit into from
Mar 14, 2023

Conversation

devigned
Copy link
Member

@devigned devigned commented Mar 2, 2023

Currently, handle_run does not enable the caller to specify I/O redirection for modules running in slight. This PR allows the caller of handle_run to specify paths for std{out, in, err} which will be used to redirect WASI stdio.

Out of scope for the PR:

  • Adding command line args to slight

@devigned devigned force-pushed the ioredirect branch 6 times, most recently from ac438b5 to 7bf15d0 Compare March 2, 2023 19:40
@devigned devigned marked this pull request as draft March 2, 2023 23:12
@devigned
Copy link
Member Author

devigned commented Mar 2, 2023

Going to give this a bit more testing. I'm running into 502 errors when running this in the containerd-shim.

crates/runtime/src/lib.rs Outdated Show resolved Hide resolved
src/commands/run.rs Show resolved Hide resolved
@Mossaka
Copy link
Member

Mossaka commented Mar 8, 2023

Let me know if this is ready to review again @devigned

@devigned
Copy link
Member Author

devigned commented Mar 8, 2023

Let me know if this is ready to review again @devigned

I think this last push should satisfy the linter. Should be good to go.

@devigned devigned marked this pull request as ready for review March 8, 2023 21:46
@devigned
Copy link
Member Author

@danbugs and @Mossaka, can I get another review?

Copy link
Member

@Mossaka Mossaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! Left some comments

crates/runtime/src/lib.rs Outdated Show resolved Hide resolved
crates/runtime/src/lib.rs Show resolved Hide resolved
crates/runtime/src/lib.rs Show resolved Hide resolved
crates/runtime/src/lib.rs Outdated Show resolved Hide resolved
crates/runtime/src/lib.rs Outdated Show resolved Hide resolved
src/commands/run.rs Show resolved Hide resolved
src/commands/run.rs Show resolved Hide resolved
src/commands/test/slightfile.toml Show resolved Hide resolved
tests/io-test/slightfile.toml Show resolved Hide resolved
@devigned
Copy link
Member Author

@Mossaka I've updated the PR based on your feedback. Ready for the next round of reviews.

@devigned devigned added the ✨ feature New feature or feature request label Mar 13, 2023
Copy link
Member

@Mossaka Mossaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Again, thank you @devigned

@devigned devigned merged commit 5e71d2b into deislabs:main Mar 14, 2023
@devigned devigned deleted the ioredirect branch March 14, 2023 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ feature New feature or feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants