Uh oh!
There was an error while loading. Please reload this page.
add omitempty to 'Devices - #340
Conversation
mrunalp
commented
Mar 10, 2016
LGTM |
| @@ -130,7 +130,7 @@ type Linux struct { | |||
| // Namespaces contains the namespaces that are created and/or joined by the container | |||
| Namespaces []Namespace `json:"namespaces"` | |||
There was a problem hiding this comment.
Aren't namespaces optional as well?
crosbymichael
commented
Mar 10, 2016
Why do we have to remove fields from the EXAMPLES? They are examples, if you don't have fields in examples where are people going to learn about them? |
wking
commented
Mar 10, 2016
On Thu, Mar 10, 2016 at 10:25:56AM -0800, Michael Crosby wrote:
I think we should either remove optional fields or fill them in with |
liangchenye
commented
Mar 11, 2016
Same with Wking, I think we can just keep the meaningful value. |
| * **`type`** *(string, required)* - type of device: "c", "b", "u" or "p". | ||
| More info in [mknod(1)][mknod.1]. | ||
| * **`path`** *(string, required)* - full path to device inside container. | ||
| * **`major, minor`** *(int64, required unless **`type`** is `p`)* - [major, minor numbers][devices] for the device. |
There was a problem hiding this comment.
You might want to change p here and below in Device whitelist section as well. Anyway I don't see this necessary, because I don't think there is inkling for a specific type with backticks since it's just consistent usage for markdown. See discussion in #323 (comment)
There was a problem hiding this comment.
On Thu, Mar 10, 2016 at 06:36:58PM -0800, Qiang Huang wrote:
@@ -99,7 +99,7 @@ The runtime may supply them however it likes (with [mknod][mknod.2], by bind mou
The following parameters can be specified:
-*
type(string, required) - type of device:c,b,uorp.
+*type(string, required) - type of device: "c", "b", "u" or "p".
More info in [mknod(1)][mknod.1].
path(string, required) - full path to device inside container.major, minor(int64, required unless *type** isp)* - [major, minor numbers][devices] for the device.You might want to change
phere and below inDevice whitelist
section as well. Anyway I don't see this necessary, because I don't
think there is inkling for a specific type with backticks since it's
just consistent usage for markdown. See discussion in
#323 (comment)
I think the style we choose is less important thant that we pick
something and document it in 1 for consistency. Having to think
about this whenever someone inserts a string literal in new docs is
wasted time ;).
Signed-off-by: liangchenye <liangchenye@huawei.com>
liangchenye
commented
Mar 11, 2016
vbatts
commented
Mar 16, 2016
LGTM and while this removes the empty values, i'll fix via #344 |
To match the omitempty which the Go property has had since 28cc423 (add omitempty to 'Device' and 'Namespace', 2016-03-10, opencontainers#340). Signed-off-by: W. Trevor King <wking@tremily.us>
To match the omitempty which the Go property has had since 28cc423 (add omitempty to 'Device' and 'Namespace', 2016-03-10, opencontainers#340). Signed-off-by: W. Trevor King <wking@tremily.us>
To match the omitempty which the Go property has had since 28cc423 (add omitempty to 'Device' and 'Namespace', 2016-03-10, opencontainers#340). Signed-off-by: W. Trevor King <wking@tremily.us>
cto "c" since it became a string.Signed-off-by: liangchenye liangchenye@huawei.com