-
Notifications
You must be signed in to change notification settings - Fork 269
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# GPU host requirement | ||
|
||
## Goal | ||
|
||
This proposal adds support for GPU to the existing support for host requirements. | ||
- Issue: https://github.com/devcontainers/spec/issues/82 | ||
- Community PR: https://github.com/devcontainers/cli/pull/173 | ||
|
||
## Proposal | ||
|
||
We propose to add a new `gpu` property to the `hostRequirements` object in the devcontainer.json schema. The property can be a boolean value, the string `optional` or an object: | ||
|
||
(Additional row for the existing table in the spec.) | ||
| Property | Type | Description | | ||
|----------|------|-------------| | ||
| `hostRequirements.gpu` 🏷️ | boolean \| 'optional' | Indicates whether or not a GPU is required. A value 'optional' indicates that might be used if available. The object is described in the table below. The default is false. For example: `"hostRequirements": "optional"` | | ||
|
||
The object value can have the following properties: | ||
|
||
| Property | Type | Description | | ||
|----------|------|-------------| | ||
| `hostRequirements.gpu.cores` 🏷️ | integer | Indicates the minimum required number of cores. For example: `"hostRequirements": { "gpu": {"cores": 2} }` | | ||
| `hostRequirements.gpu.memory` 🏷️ | string | A string indicating minimum memory requirements with a `tb`, `gb`, `mb`, or `kb` suffix. For example, `"hostRequirements": {"memory": "4gb"}` | |