Skip to content

Commit

Permalink
Add Devices protos
Browse files Browse the repository at this point in the history
Adds the protocol buffers needed to support allocation of devices in
swarmkit. Part of the proposal in moby#2682.

Signed-off-by: Drew Erny <[email protected]>
  • Loading branch information
dperny committed Aug 24, 2018
1 parent cfa742c commit c3f3fea
Show file tree
Hide file tree
Showing 8 changed files with 1,914 additions and 589 deletions.
134 changes: 125 additions & 9 deletions api/api.pb.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2491,8 +2491,8 @@ file {
label: LABEL_OPTIONAL
type: TYPE_UINT32
options {
65001: 0
65003: "os.FileMode"
65001: 0
}
json_name: "mode"
}
Expand Down Expand Up @@ -2639,8 +2639,8 @@ file {
type: TYPE_MESSAGE
type_name: ".google.protobuf.Duration"
options {
65001: 0
65011: 1
65001: 0
}
json_name: "delay"
}
Expand Down Expand Up @@ -3083,8 +3083,8 @@ file {
}
}
options {
62001: 0
62023: "PublishMode"
62001: 0
}
}
}
Expand Down Expand Up @@ -3783,8 +3783,8 @@ file {
label: LABEL_OPTIONAL
type: TYPE_UINT32
options {
65001: 0
65003: "os.FileMode"
65001: 0
}
json_name: "mode"
}
Expand Down Expand Up @@ -4063,6 +4063,54 @@ file {
}
}
}
message_type {
name: "Device"
field {
name: "device_class_id"
number: 1
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "deviceClassId"
}
field {
name: "path_on_host"
number: 2
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "pathOnHost"
}
}
message_type {
name: "DeviceAttachment"
field {
name: "device_class_id"
number: 1
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "deviceClassId"
}
field {
name: "path_on_host"
number: 2
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "pathOnHost"
}
field {
name: "path_in_task"
number: 3
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "pathInTask"
}
field {
name: "device_cgroup_rules"
number: 16
label: LABEL_REPEATED
type: TYPE_STRING
json_name: "deviceCgroupRules"
}
}
enum_type {
name: "ResourceType"
value {
Expand Down Expand Up @@ -4200,8 +4248,8 @@ file {
}
}
options {
62001: 0
62023: "NodeRole"
62001: 0
}
}
syntax: "proto3"
Expand Down Expand Up @@ -4385,6 +4433,14 @@ file {
type_name: ".docker.swarmkit.v1.NodeSpec.Availability"
json_name: "availability"
}
field {
name: "devices"
number: 5
label: LABEL_REPEATED
type: TYPE_MESSAGE
type_name: ".docker.swarmkit.v1.Device"
json_name: "devices"
}
enum_type {
name: "Membership"
value {
Expand Down Expand Up @@ -4654,6 +4710,30 @@ file {
json_name: "payload"
}
}
message_type {
name: "DeviceAttachmentSpec"
field {
name: "device_class"
number: 1
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "deviceClass"
}
field {
name: "path"
number: 2
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "path"
}
field {
name: "device_cgroup_rules"
number: 16
label: LABEL_REPEATED
type: TYPE_STRING
json_name: "deviceCgroupRules"
}
}
message_type {
name: "NetworkAttachmentSpec"
field {
Expand Down Expand Up @@ -5961,6 +6041,14 @@ file {
type_name: ".docker.swarmkit.v1.GenericResource"
json_name: "assignedGenericResources"
}
field {
name: "devices"
number: 16
label: LABEL_REPEATED
type: TYPE_MESSAGE
type_name: ".docker.swarmkit.v1.DeviceAttachment"
json_name: "devices"
}
options {
70001 {
1 {
Expand Down Expand Up @@ -6321,6 +6409,34 @@ file {
}
}
}
message_type {
name: "DeviceClass"
field {
name: "id"
number: 1
label: LABEL_OPTIONAL
type: TYPE_STRING
json_name: "id"
}
field {
name: "meta"
number: 2
label: LABEL_OPTIONAL
type: TYPE_MESSAGE
type_name: ".docker.swarmkit.v1.Meta"
options {
65001: 0
}
json_name: "meta"
}
field {
name: "shared"
number: 3
label: LABEL_OPTIONAL
type: TYPE_BOOL
json_name: "shared"
}
}
message_type {
name: "Resource"
field {
Expand Down Expand Up @@ -8023,8 +8139,8 @@ file {
type: TYPE_MESSAGE
type_name: ".google.protobuf.Duration"
options {
65001: 0
65011: 1
65001: 0
}
json_name: "period"
}
Expand Down Expand Up @@ -9071,11 +9187,11 @@ file {
}
}
options {
63001: 0
63002: 0
63017: 1
63018: 1
63020: 1
63018: 1
63001: 0
63002: 0
}
}
file {
Expand Down
4 changes: 4 additions & 0 deletions api/ca.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit c3f3fea

Please sign in to comment.