Skip to content

Commit

Permalink
Add GPU host requirement properties (devcontainers/spec#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
chrmarti committed Nov 28, 2022
1 parent 6eb07d0 commit 9dba538
Show file tree
Hide file tree
Showing 2 changed files with 197 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,39 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements.",
"additionalProperties": false
}
]
}
},
"additionalProperties": false
Expand Down Expand Up @@ -1135,6 +1168,39 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements.",
"additionalProperties": false
}
]
}
},
"additionalProperties": false
Expand Down Expand Up @@ -1777,6 +1843,39 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements.",
"additionalProperties": false
}
]
}
},
"additionalProperties": false
Expand Down Expand Up @@ -2411,6 +2510,39 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements.",
"additionalProperties": false
}
]
}
},
"additionalProperties": false
Expand Down Expand Up @@ -3010,6 +3142,39 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements.",
"additionalProperties": false
}
]
}
},
"additionalProperties": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,38 @@
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required disk space in bytes. Supports units tb, gb, mb and kb."
},
"gpu": {
"oneOf": [
{
"type": [
"boolean",
"string"
],
"enum": [
true,
false,
"optional"
],
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
},
{
"type": "object",
"properties": {
"cores": {
"type": "integer",
"minimum": 1,
"description": "Number of required cores."
},
"memory": {
"type": "string",
"pattern": "^\\d+([tgmk]b)?$",
"description": "Amount of required RAM in bytes. Supports units tb, gb, mb and kb."
}
},
"description": "Indicates whether a GPU is required. The string \"optional\" indicates that a GPU is optional. An object value can be used to configure more detailed requirements."
}
]
}
}
}
Expand Down

0 comments on commit 9dba538

Please sign in to comment.