Skip to content

feat(cli): add generic sandbox device request flags#629

Closed
cheese-head wants to merge 1 commit intoNVIDIA:mainfrom
cheese-head:628-sandbox-device-flags/cheese-head
Closed

feat(cli): add generic sandbox device request flags#629
cheese-head wants to merge 1 commit intoNVIDIA:mainfrom
cheese-head:628-sandbox-device-flags/cheese-head

Conversation

@cheese-head
Copy link
Copy Markdown

Summary

Add generic sandbox device request flags to the CLI by introducing --resource and --runtime-class while keeping --gpu as the single-GPU compatibility shorthand.

Related Issue

Closes #628

Changes

  • Added --resource <NAME=COUNT> to openshell sandbox create
  • Added --runtime-class <RUNTIME_CLASS> to openshell sandbox create
  • Mapped those flags onto the existing sandbox template resources and runtime_class_name fields
  • Added validation for conflicting GPU request styles
  • Updated CLI tests and user-facing docs

Testing

  • mise run pre-commit passes
  • Unit tests added/updated
  • E2E tests added/updated (if applicable)

Notes:

  • Ran cargo fmt --all
  • Ran cargo test -p openshell-cli
  • Verified a sandbox created with --resource nvidia.com/gpu=2 --runtime-class nvidia exposed two GPUs via nvidia-smi
  • mise run pre-commit is currently blocked by an unrelated failure in openshell-sandbox:
    • process::tests::drop_privileges_succeeds_for_current_user

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (if applicable)

Signed-off-by: Patrick Riel <priel@nvidia.com>
@github-actions
Copy link
Copy Markdown

Thank you for your interest in contributing to OpenShell, @cheese-head.

This project uses a vouch system for first-time contributors. Before submitting a pull request, you need to be vouched by a maintainer.

To get vouched:

  1. Open a Vouch Request discussion.
  2. Describe what you want to change and why.
  3. Write in your own words — do not have an AI generate the request.
  4. A maintainer will comment /vouch if approved.
  5. Once vouched, open a new PR (preferred) or reopen this one after a few minutes.

See CONTRIBUTING.md for details.

@github-actions github-actions bot closed this Mar 26, 2026
@github-actions
Copy link
Copy Markdown

Thank you for your submission! We ask that you sign our Developer Certificate of Origin before we can accept your contribution. You can sign the DCO by adding a comment below using this text:


I have read the DCO document and I hereby sign the DCO.


You can retrigger this bot by commenting recheck in this Pull Request. Posted by the DCO Assistant Lite bot.

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

Successfully merging this pull request may close these issues.

feat(cli): add generic sandbox device request flags

1 participant