/
types.pb.go
17932 lines (17193 loc) · 449 KB
/
types.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: github.com/docker/swarmkit/api/types.proto
package api
import proto "github.com/gogo/protobuf/proto"
import fmt "fmt"
import math "math"
import google_protobuf "github.com/gogo/protobuf/types"
import google_protobuf1 "github.com/gogo/protobuf/types"
import google_protobuf2 "github.com/gogo/protobuf/types"
import _ "github.com/gogo/protobuf/gogoproto"
import os "os"
import time "time"
import deepcopy "github.com/docker/swarmkit/api/deepcopy"
import binary "encoding/binary"
import types "github.com/gogo/protobuf/types"
import strings "strings"
import reflect "reflect"
import sortkeys "github.com/gogo/protobuf/sortkeys"
import io "io"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
var _ = time.Kitchen
type ResourceType int32
const (
ResourceType_TASK ResourceType = 0
ResourceType_SECRET ResourceType = 1
ResourceType_CONFIG ResourceType = 2
)
var ResourceType_name = map[int32]string{
0: "TASK",
1: "SECRET",
2: "CONFIG",
}
var ResourceType_value = map[string]int32{
"TASK": 0,
"SECRET": 1,
"CONFIG": 2,
}
func (x ResourceType) String() string {
return proto.EnumName(ResourceType_name, int32(x))
}
func (ResourceType) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{0} }
// Only the manager create a NEW task, and move the task to PENDING and ASSIGNED.
// Afterward, the manager must rely on the agent to update the task status
// (pre-run: preparing, ready, starting;
// running;
// end-state: complete, shutdown, failed, rejected)
type TaskState int32
const (
TaskStateNew TaskState = 0
TaskStatePending TaskState = 64
TaskStateAssigned TaskState = 192
TaskStateAccepted TaskState = 256
TaskStatePreparing TaskState = 320
TaskStateReady TaskState = 384
TaskStateStarting TaskState = 448
TaskStateRunning TaskState = 512
TaskStateCompleted TaskState = 576
TaskStateShutdown TaskState = 640
TaskStateFailed TaskState = 704
// TaskStateRejected means a task never ran, for instance if something about
// the environment failed (e.g. setting up a port on that node failed).
TaskStateRejected TaskState = 768
// TaskStateRemove is used to correctly handle service deletions and scale
// downs. This allows us to keep track of tasks that have been marked for
// deletion, but can't yet be removed because the agent is in the process of
// shutting them down. Once the agent has shut down tasks with desired state
// REMOVE, the task reaper is responsible for removing them.
TaskStateRemove TaskState = 800
// TaskStateOrphaned is used to free up resources associated with service
// tasks on unresponsive nodes without having to delete those tasks. This
// state is directly assigned to the task by the orchestrator.
TaskStateOrphaned TaskState = 832
)
var TaskState_name = map[int32]string{
0: "NEW",
64: "PENDING",
192: "ASSIGNED",
256: "ACCEPTED",
320: "PREPARING",
384: "READY",
448: "STARTING",
512: "RUNNING",
576: "COMPLETE",
640: "SHUTDOWN",
704: "FAILED",
768: "REJECTED",
800: "REMOVE",
832: "ORPHANED",
}
var TaskState_value = map[string]int32{
"NEW": 0,
"PENDING": 64,
"ASSIGNED": 192,
"ACCEPTED": 256,
"PREPARING": 320,
"READY": 384,
"STARTING": 448,
"RUNNING": 512,
"COMPLETE": 576,
"SHUTDOWN": 640,
"FAILED": 704,
"REJECTED": 768,
"REMOVE": 800,
"ORPHANED": 832,
}
func (x TaskState) String() string {
return proto.EnumName(TaskState_name, int32(x))
}
func (TaskState) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{1} }
type NodeRole int32
const (
NodeRoleWorker NodeRole = 0
NodeRoleManager NodeRole = 1
)
var NodeRole_name = map[int32]string{
0: "WORKER",
1: "MANAGER",
}
var NodeRole_value = map[string]int32{
"WORKER": 0,
"MANAGER": 1,
}
func (x NodeRole) String() string {
return proto.EnumName(NodeRole_name, int32(x))
}
func (NodeRole) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{2} }
type RaftMemberStatus_Reachability int32
const (
// Unknown indicates that the manager state cannot be resolved
RaftMemberStatus_UNKNOWN RaftMemberStatus_Reachability = 0
// Unreachable indicates that the node cannot be contacted by other
// raft cluster members.
RaftMemberStatus_UNREACHABLE RaftMemberStatus_Reachability = 1
// Reachable indicates that the node is healthy and reachable
// by other members.
RaftMemberStatus_REACHABLE RaftMemberStatus_Reachability = 2
)
var RaftMemberStatus_Reachability_name = map[int32]string{
0: "UNKNOWN",
1: "UNREACHABLE",
2: "REACHABLE",
}
var RaftMemberStatus_Reachability_value = map[string]int32{
"UNKNOWN": 0,
"UNREACHABLE": 1,
"REACHABLE": 2,
}
func (x RaftMemberStatus_Reachability) String() string {
return proto.EnumName(RaftMemberStatus_Reachability_name, int32(x))
}
func (RaftMemberStatus_Reachability) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{13, 0}
}
// TODO(aluzzardi) These should be using `gogoproto.enumvalue_customname`.
type NodeStatus_State int32
const (
// Unknown indicates the node state cannot be resolved.
NodeStatus_UNKNOWN NodeStatus_State = 0
// Down indicates the node is down.
NodeStatus_DOWN NodeStatus_State = 1
// Ready indicates the node is ready to accept tasks.
NodeStatus_READY NodeStatus_State = 2
// Disconnected indicates the node is currently trying to find new manager.
NodeStatus_DISCONNECTED NodeStatus_State = 3
)
var NodeStatus_State_name = map[int32]string{
0: "UNKNOWN",
1: "DOWN",
2: "READY",
3: "DISCONNECTED",
}
var NodeStatus_State_value = map[string]int32{
"UNKNOWN": 0,
"DOWN": 1,
"READY": 2,
"DISCONNECTED": 3,
}
func (x NodeStatus_State) String() string {
return proto.EnumName(NodeStatus_State_name, int32(x))
}
func (NodeStatus_State) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{14, 0} }
type Mount_MountType int32
const (
MountTypeBind Mount_MountType = 0
MountTypeVolume Mount_MountType = 1
MountTypeTmpfs Mount_MountType = 2
MountTypeNamedPipe Mount_MountType = 3
)
var Mount_MountType_name = map[int32]string{
0: "BIND",
1: "VOLUME",
2: "TMPFS",
3: "NPIPE",
}
var Mount_MountType_value = map[string]int32{
"BIND": 0,
"VOLUME": 1,
"TMPFS": 2,
"NPIPE": 3,
}
func (x Mount_MountType) String() string {
return proto.EnumName(Mount_MountType_name, int32(x))
}
func (Mount_MountType) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{16, 0} }
// Consistency indicates the tolerable level of file system consistency
type Mount_MountConsistency int32
const (
MountConsistencyDefault Mount_MountConsistency = 0
MountConsistencyFull Mount_MountConsistency = 1
MountConsistencyCached Mount_MountConsistency = 2
MountConsistencyDelegated Mount_MountConsistency = 3
)
var Mount_MountConsistency_name = map[int32]string{
0: "DEFAULT",
1: "CONSISTENT",
2: "CACHED",
3: "DELEGATED",
}
var Mount_MountConsistency_value = map[string]int32{
"DEFAULT": 0,
"CONSISTENT": 1,
"CACHED": 2,
"DELEGATED": 3,
}
func (x Mount_MountConsistency) String() string {
return proto.EnumName(Mount_MountConsistency_name, int32(x))
}
func (Mount_MountConsistency) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{16, 1}
}
type Mount_BindOptions_MountPropagation int32
const (
MountPropagationRPrivate Mount_BindOptions_MountPropagation = 0
MountPropagationPrivate Mount_BindOptions_MountPropagation = 1
MountPropagationRShared Mount_BindOptions_MountPropagation = 2
MountPropagationShared Mount_BindOptions_MountPropagation = 3
MountPropagationRSlave Mount_BindOptions_MountPropagation = 4
MountPropagationSlave Mount_BindOptions_MountPropagation = 5
)
var Mount_BindOptions_MountPropagation_name = map[int32]string{
0: "RPRIVATE",
1: "PRIVATE",
2: "RSHARED",
3: "SHARED",
4: "RSLAVE",
5: "SLAVE",
}
var Mount_BindOptions_MountPropagation_value = map[string]int32{
"RPRIVATE": 0,
"PRIVATE": 1,
"RSHARED": 2,
"SHARED": 3,
"RSLAVE": 4,
"SLAVE": 5,
}
func (x Mount_BindOptions_MountPropagation) String() string {
return proto.EnumName(Mount_BindOptions_MountPropagation_name, int32(x))
}
func (Mount_BindOptions_MountPropagation) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{16, 0, 0}
}
type RestartPolicy_RestartCondition int32
const (
RestartOnNone RestartPolicy_RestartCondition = 0
RestartOnFailure RestartPolicy_RestartCondition = 1
RestartOnAny RestartPolicy_RestartCondition = 2
)
var RestartPolicy_RestartCondition_name = map[int32]string{
0: "NONE",
1: "ON_FAILURE",
2: "ANY",
}
var RestartPolicy_RestartCondition_value = map[string]int32{
"NONE": 0,
"ON_FAILURE": 1,
"ANY": 2,
}
func (x RestartPolicy_RestartCondition) String() string {
return proto.EnumName(RestartPolicy_RestartCondition_name, int32(x))
}
func (RestartPolicy_RestartCondition) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{17, 0}
}
type UpdateConfig_FailureAction int32
const (
UpdateConfig_PAUSE UpdateConfig_FailureAction = 0
UpdateConfig_CONTINUE UpdateConfig_FailureAction = 1
UpdateConfig_ROLLBACK UpdateConfig_FailureAction = 2
)
var UpdateConfig_FailureAction_name = map[int32]string{
0: "PAUSE",
1: "CONTINUE",
2: "ROLLBACK",
}
var UpdateConfig_FailureAction_value = map[string]int32{
"PAUSE": 0,
"CONTINUE": 1,
"ROLLBACK": 2,
}
func (x UpdateConfig_FailureAction) String() string {
return proto.EnumName(UpdateConfig_FailureAction_name, int32(x))
}
func (UpdateConfig_FailureAction) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{18, 0}
}
// UpdateOrder controls the order of operations when rolling out an
// updated task. Either the old task is shut down before the new task
// is started, or the new task is started before the old task is shut
// down.
type UpdateConfig_UpdateOrder int32
const (
UpdateConfig_STOP_FIRST UpdateConfig_UpdateOrder = 0
UpdateConfig_START_FIRST UpdateConfig_UpdateOrder = 1
)
var UpdateConfig_UpdateOrder_name = map[int32]string{
0: "STOP_FIRST",
1: "START_FIRST",
}
var UpdateConfig_UpdateOrder_value = map[string]int32{
"STOP_FIRST": 0,
"START_FIRST": 1,
}
func (x UpdateConfig_UpdateOrder) String() string {
return proto.EnumName(UpdateConfig_UpdateOrder_name, int32(x))
}
func (UpdateConfig_UpdateOrder) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{18, 1}
}
type UpdateStatus_UpdateState int32
const (
UpdateStatus_UNKNOWN UpdateStatus_UpdateState = 0
UpdateStatus_UPDATING UpdateStatus_UpdateState = 1
UpdateStatus_PAUSED UpdateStatus_UpdateState = 2
UpdateStatus_COMPLETED UpdateStatus_UpdateState = 3
UpdateStatus_ROLLBACK_STARTED UpdateStatus_UpdateState = 4
UpdateStatus_ROLLBACK_PAUSED UpdateStatus_UpdateState = 5
UpdateStatus_ROLLBACK_COMPLETED UpdateStatus_UpdateState = 6
)
var UpdateStatus_UpdateState_name = map[int32]string{
0: "UNKNOWN",
1: "UPDATING",
2: "PAUSED",
3: "COMPLETED",
4: "ROLLBACK_STARTED",
5: "ROLLBACK_PAUSED",
6: "ROLLBACK_COMPLETED",
}
var UpdateStatus_UpdateState_value = map[string]int32{
"UNKNOWN": 0,
"UPDATING": 1,
"PAUSED": 2,
"COMPLETED": 3,
"ROLLBACK_STARTED": 4,
"ROLLBACK_PAUSED": 5,
"ROLLBACK_COMPLETED": 6,
}
func (x UpdateStatus_UpdateState) String() string {
return proto.EnumName(UpdateStatus_UpdateState_name, int32(x))
}
func (UpdateStatus_UpdateState) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{19, 0}
}
// AddressFamily specifies the network address family that
// this IPAMConfig belongs to.
type IPAMConfig_AddressFamily int32
const (
IPAMConfig_UNKNOWN IPAMConfig_AddressFamily = 0
IPAMConfig_IPV4 IPAMConfig_AddressFamily = 4
IPAMConfig_IPV6 IPAMConfig_AddressFamily = 6
)
var IPAMConfig_AddressFamily_name = map[int32]string{
0: "UNKNOWN",
4: "IPV4",
6: "IPV6",
}
var IPAMConfig_AddressFamily_value = map[string]int32{
"UNKNOWN": 0,
"IPV4": 4,
"IPV6": 6,
}
func (x IPAMConfig_AddressFamily) String() string {
return proto.EnumName(IPAMConfig_AddressFamily_name, int32(x))
}
func (IPAMConfig_AddressFamily) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{24, 0}
}
type PortConfig_Protocol int32
const (
ProtocolTCP PortConfig_Protocol = 0
ProtocolUDP PortConfig_Protocol = 1
ProtocolSCTP PortConfig_Protocol = 2
)
var PortConfig_Protocol_name = map[int32]string{
0: "TCP",
1: "UDP",
2: "SCTP",
}
var PortConfig_Protocol_value = map[string]int32{
"TCP": 0,
"UDP": 1,
"SCTP": 2,
}
func (x PortConfig_Protocol) String() string {
return proto.EnumName(PortConfig_Protocol_name, int32(x))
}
func (PortConfig_Protocol) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{25, 0} }
// PublishMode controls how ports are published on the swarm.
type PortConfig_PublishMode int32
const (
// PublishModeIngress exposes the port across the cluster on all nodes.
PublishModeIngress PortConfig_PublishMode = 0
// PublishModeHost exposes the port on just the target host. If the
// published port is undefined, an ephemeral port will be allocated. If
// the published port is defined, the node will attempt to allocate it,
// erroring the task if it fails.
PublishModeHost PortConfig_PublishMode = 1
)
var PortConfig_PublishMode_name = map[int32]string{
0: "INGRESS",
1: "HOST",
}
var PortConfig_PublishMode_value = map[string]int32{
"INGRESS": 0,
"HOST": 1,
}
func (x PortConfig_PublishMode) String() string {
return proto.EnumName(PortConfig_PublishMode_name, int32(x))
}
func (PortConfig_PublishMode) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{25, 1}
}
type IssuanceStatus_State int32
const (
IssuanceStateUnknown IssuanceStatus_State = 0
// A new certificate should be issued
IssuanceStateRenew IssuanceStatus_State = 1
// Certificate is pending acceptance
IssuanceStatePending IssuanceStatus_State = 2
// successful completion certificate issuance
IssuanceStateIssued IssuanceStatus_State = 3
// Certificate issuance failed
IssuanceStateFailed IssuanceStatus_State = 4
// Signals workers to renew their certificate. From the CA's perspective
// this is equivalent to IssuanceStateIssued: a noop.
IssuanceStateRotate IssuanceStatus_State = 5
)
var IssuanceStatus_State_name = map[int32]string{
0: "UNKNOWN",
1: "RENEW",
2: "PENDING",
3: "ISSUED",
4: "FAILED",
5: "ROTATE",
}
var IssuanceStatus_State_value = map[string]int32{
"UNKNOWN": 0,
"RENEW": 1,
"PENDING": 2,
"ISSUED": 3,
"FAILED": 4,
"ROTATE": 5,
}
func (x IssuanceStatus_State) String() string {
return proto.EnumName(IssuanceStatus_State_name, int32(x))
}
func (IssuanceStatus_State) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{30, 0} }
type ExternalCA_CAProtocol int32
const (
ExternalCA_CAProtocolCFSSL ExternalCA_CAProtocol = 0
)
var ExternalCA_CAProtocol_name = map[int32]string{
0: "CFSSL",
}
var ExternalCA_CAProtocol_value = map[string]int32{
"CFSSL": 0,
}
func (x ExternalCA_CAProtocol) String() string {
return proto.EnumName(ExternalCA_CAProtocol_name, int32(x))
}
func (ExternalCA_CAProtocol) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{32, 0}
}
// Encryption algorithm that can implemented using this key
type EncryptionKey_Algorithm int32
const (
AES_128_GCM EncryptionKey_Algorithm = 0
)
var EncryptionKey_Algorithm_name = map[int32]string{
0: "AES_128_GCM",
}
var EncryptionKey_Algorithm_value = map[string]int32{
"AES_128_GCM": 0,
}
func (x EncryptionKey_Algorithm) String() string {
return proto.EnumName(EncryptionKey_Algorithm_name, int32(x))
}
func (EncryptionKey_Algorithm) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{45, 0}
}
type MaybeEncryptedRecord_Algorithm int32
const (
MaybeEncryptedRecord_NotEncrypted MaybeEncryptedRecord_Algorithm = 0
MaybeEncryptedRecord_NACLSecretboxSalsa20Poly1305 MaybeEncryptedRecord_Algorithm = 1
MaybeEncryptedRecord_FernetAES128CBC MaybeEncryptedRecord_Algorithm = 2
)
var MaybeEncryptedRecord_Algorithm_name = map[int32]string{
0: "NONE",
1: "SECRETBOX_SALSA20_POLY1305",
2: "FERNET_AES_128_CBC",
}
var MaybeEncryptedRecord_Algorithm_value = map[string]int32{
"NONE": 0,
"SECRETBOX_SALSA20_POLY1305": 1,
"FERNET_AES_128_CBC": 2,
}
func (x MaybeEncryptedRecord_Algorithm) String() string {
return proto.EnumName(MaybeEncryptedRecord_Algorithm_name, int32(x))
}
func (MaybeEncryptedRecord_Algorithm) EnumDescriptor() ([]byte, []int) {
return fileDescriptorTypes, []int{53, 0}
}
// Version tracks the last time an object in the store was updated.
type Version struct {
Index uint64 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"`
}
func (m *Version) Reset() { *m = Version{} }
func (*Version) ProtoMessage() {}
func (*Version) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{0} }
type IndexEntry struct {
Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
Val string `protobuf:"bytes,2,opt,name=val,proto3" json:"val,omitempty"`
}
func (m *IndexEntry) Reset() { *m = IndexEntry{} }
func (*IndexEntry) ProtoMessage() {}
func (*IndexEntry) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{1} }
// Annotations provide useful information to identify API objects. They are
// common to all API specs.
type Annotations struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Labels map[string]string `protobuf:"bytes,2,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
// Indices provides keys and values for indexing this object.
// A single key may have multiple values.
Indices []IndexEntry `protobuf:"bytes,4,rep,name=indices" json:"indices"`
}
func (m *Annotations) Reset() { *m = Annotations{} }
func (*Annotations) ProtoMessage() {}
func (*Annotations) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{2} }
// NamedGenericResource represents a "user defined" resource which is defined
// as a string.
// "Kind" is used to describe the Kind of a resource (e.g: "GPU", "FPGA", "SSD", ...)
// Value is used to identify the resource (GPU="UUID-1", FPGA="/dev/sdb5", ...)
type NamedGenericResource struct {
Kind string `protobuf:"bytes,1,opt,name=kind,proto3" json:"kind,omitempty"`
Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
}
func (m *NamedGenericResource) Reset() { *m = NamedGenericResource{} }
func (*NamedGenericResource) ProtoMessage() {}
func (*NamedGenericResource) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{3} }
// DiscreteGenericResource represents a "user defined" resource which is defined
// as an integer
// "Kind" is used to describe the Kind of a resource (e.g: "GPU", "FPGA", "SSD", ...)
// Value is used to count the resource (SSD=5, HDD=3, ...)
type DiscreteGenericResource struct {
Kind string `protobuf:"bytes,1,opt,name=kind,proto3" json:"kind,omitempty"`
Value int64 `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
}
func (m *DiscreteGenericResource) Reset() { *m = DiscreteGenericResource{} }
func (*DiscreteGenericResource) ProtoMessage() {}
func (*DiscreteGenericResource) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{4} }
// GenericResource represents a "user defined" resource which can
// be either an integer (e.g: SSD=3) or a string (e.g: SSD=sda1)
type GenericResource struct {
// Types that are valid to be assigned to Resource:
// *GenericResource_NamedResourceSpec
// *GenericResource_DiscreteResourceSpec
Resource isGenericResource_Resource `protobuf_oneof:"resource"`
}
func (m *GenericResource) Reset() { *m = GenericResource{} }
func (*GenericResource) ProtoMessage() {}
func (*GenericResource) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{5} }
type isGenericResource_Resource interface {
isGenericResource_Resource()
MarshalTo([]byte) (int, error)
Size() int
}
type GenericResource_NamedResourceSpec struct {
NamedResourceSpec *NamedGenericResource `protobuf:"bytes,1,opt,name=named_resource_spec,json=namedResourceSpec,oneof"`
}
type GenericResource_DiscreteResourceSpec struct {
DiscreteResourceSpec *DiscreteGenericResource `protobuf:"bytes,2,opt,name=discrete_resource_spec,json=discreteResourceSpec,oneof"`
}
func (*GenericResource_NamedResourceSpec) isGenericResource_Resource() {}
func (*GenericResource_DiscreteResourceSpec) isGenericResource_Resource() {}
func (m *GenericResource) GetResource() isGenericResource_Resource {
if m != nil {
return m.Resource
}
return nil
}
func (m *GenericResource) GetNamedResourceSpec() *NamedGenericResource {
if x, ok := m.GetResource().(*GenericResource_NamedResourceSpec); ok {
return x.NamedResourceSpec
}
return nil
}
func (m *GenericResource) GetDiscreteResourceSpec() *DiscreteGenericResource {
if x, ok := m.GetResource().(*GenericResource_DiscreteResourceSpec); ok {
return x.DiscreteResourceSpec
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*GenericResource) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _GenericResource_OneofMarshaler, _GenericResource_OneofUnmarshaler, _GenericResource_OneofSizer, []interface{}{
(*GenericResource_NamedResourceSpec)(nil),
(*GenericResource_DiscreteResourceSpec)(nil),
}
}
func _GenericResource_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*GenericResource)
// resource
switch x := m.Resource.(type) {
case *GenericResource_NamedResourceSpec:
_ = b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.NamedResourceSpec); err != nil {
return err
}
case *GenericResource_DiscreteResourceSpec:
_ = b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.DiscreteResourceSpec); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("GenericResource.Resource has unexpected type %T", x)
}
return nil
}
func _GenericResource_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*GenericResource)
switch tag {
case 1: // resource.named_resource_spec
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(NamedGenericResource)
err := b.DecodeMessage(msg)
m.Resource = &GenericResource_NamedResourceSpec{msg}
return true, err
case 2: // resource.discrete_resource_spec
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(DiscreteGenericResource)
err := b.DecodeMessage(msg)
m.Resource = &GenericResource_DiscreteResourceSpec{msg}
return true, err
default:
return false, nil
}
}
func _GenericResource_OneofSizer(msg proto.Message) (n int) {
m := msg.(*GenericResource)
// resource
switch x := m.Resource.(type) {
case *GenericResource_NamedResourceSpec:
s := proto.Size(x.NamedResourceSpec)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *GenericResource_DiscreteResourceSpec:
s := proto.Size(x.DiscreteResourceSpec)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
type Resources struct {
// Amount of CPUs (e.g. 2000000000 = 2 CPU cores)
NanoCPUs int64 `protobuf:"varint,1,opt,name=nano_cpus,json=nanoCpus,proto3" json:"nano_cpus,omitempty"`
// Amount of memory in bytes.
MemoryBytes int64 `protobuf:"varint,2,opt,name=memory_bytes,json=memoryBytes,proto3" json:"memory_bytes,omitempty"`
// User specified resource (e.g: bananas=2;apple={red,yellow,green})
Generic []*GenericResource `protobuf:"bytes,3,rep,name=generic" json:"generic,omitempty"`
}
func (m *Resources) Reset() { *m = Resources{} }
func (*Resources) ProtoMessage() {}
func (*Resources) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{6} }
type ResourceRequirements struct {
Limits *Resources `protobuf:"bytes,1,opt,name=limits" json:"limits,omitempty"`
Reservations *Resources `protobuf:"bytes,2,opt,name=reservations" json:"reservations,omitempty"`
// Amount of swap in bytes - can only be used together with a memory limit
// -1 means unlimited
// a null pointer indicates that the default behaviour of granting twice
// the memory is maintained
SwapBytes *google_protobuf2.Int64Value `protobuf:"bytes,3,opt,name=swap_bytes,json=swapBytes" json:"swap_bytes,omitempty"`
// Tune container memory swappiness (0 to 100) - if not specified, defaults
// to the container OS's default - generally 60, or the value predefined in
// the image; set to -1 to unset a previously set value
MemorySwappiness *google_protobuf2.Int64Value `protobuf:"bytes,4,opt,name=memory_swappiness,json=memorySwappiness" json:"memory_swappiness,omitempty"`
}
func (m *ResourceRequirements) Reset() { *m = ResourceRequirements{} }
func (*ResourceRequirements) ProtoMessage() {}
func (*ResourceRequirements) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{7} }
type Platform struct {
// Architecture (e.g. x86_64)
Architecture string `protobuf:"bytes,1,opt,name=architecture,proto3" json:"architecture,omitempty"`
// Operating System (e.g. linux)
OS string `protobuf:"bytes,2,opt,name=os,proto3" json:"os,omitempty"`
}
func (m *Platform) Reset() { *m = Platform{} }
func (*Platform) ProtoMessage() {}
func (*Platform) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{8} }
// PluginDescription describes an engine plugin.
type PluginDescription struct {
// Type of plugin. Canonical values for existing types are
// Volume, Network, and Authorization. More types could be
// supported in the future.
Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
// Name of the plugin
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
}
func (m *PluginDescription) Reset() { *m = PluginDescription{} }
func (*PluginDescription) ProtoMessage() {}
func (*PluginDescription) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{9} }
type EngineDescription struct {
// Docker daemon version running on the node.
EngineVersion string `protobuf:"bytes,1,opt,name=engine_version,json=engineVersion,proto3" json:"engine_version,omitempty"`
// Labels attached to the engine.
Labels map[string]string `protobuf:"bytes,2,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
// Volume, Network, and Auth plugins
Plugins []PluginDescription `protobuf:"bytes,3,rep,name=plugins" json:"plugins"`
}
func (m *EngineDescription) Reset() { *m = EngineDescription{} }
func (*EngineDescription) ProtoMessage() {}
func (*EngineDescription) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{10} }
type NodeDescription struct {
// Hostname of the node as reported by the agent.
// This is different from spec.meta.name which is user-defined.
Hostname string `protobuf:"bytes,1,opt,name=hostname,proto3" json:"hostname,omitempty"`
// Platform of the node.
Platform *Platform `protobuf:"bytes,2,opt,name=platform" json:"platform,omitempty"`
// Total resources on the node.
Resources *Resources `protobuf:"bytes,3,opt,name=resources" json:"resources,omitempty"`
// Information about the Docker Engine on the node.
Engine *EngineDescription `protobuf:"bytes,4,opt,name=engine" json:"engine,omitempty"`
// Information on the node's TLS setup
TLSInfo *NodeTLSInfo `protobuf:"bytes,5,opt,name=tls_info,json=tlsInfo" json:"tls_info,omitempty"`
// FIPS indicates whether the node has FIPS-enabled
FIPS bool `protobuf:"varint,6,opt,name=fips,proto3" json:"fips,omitempty"`
}
func (m *NodeDescription) Reset() { *m = NodeDescription{} }
func (*NodeDescription) ProtoMessage() {}
func (*NodeDescription) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{11} }
type NodeTLSInfo struct {
// Information about which root certs the node trusts
TrustRoot []byte `protobuf:"bytes,1,opt,name=trust_root,json=trustRoot,proto3" json:"trust_root,omitempty"`
// Information about the node's current TLS certificate
CertIssuerSubject []byte `protobuf:"bytes,2,opt,name=cert_issuer_subject,json=certIssuerSubject,proto3" json:"cert_issuer_subject,omitempty"`
CertIssuerPublicKey []byte `protobuf:"bytes,3,opt,name=cert_issuer_public_key,json=certIssuerPublicKey,proto3" json:"cert_issuer_public_key,omitempty"`
}
func (m *NodeTLSInfo) Reset() { *m = NodeTLSInfo{} }
func (*NodeTLSInfo) ProtoMessage() {}
func (*NodeTLSInfo) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{12} }
type RaftMemberStatus struct {
Leader bool `protobuf:"varint,1,opt,name=leader,proto3" json:"leader,omitempty"`
Reachability RaftMemberStatus_Reachability `protobuf:"varint,2,opt,name=reachability,proto3,enum=docker.swarmkit.v1.RaftMemberStatus_Reachability" json:"reachability,omitempty"`
Message string `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"`
}
func (m *RaftMemberStatus) Reset() { *m = RaftMemberStatus{} }
func (*RaftMemberStatus) ProtoMessage() {}
func (*RaftMemberStatus) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{13} }
type NodeStatus struct {
State NodeStatus_State `protobuf:"varint,1,opt,name=state,proto3,enum=docker.swarmkit.v1.NodeStatus_State" json:"state,omitempty"`
Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
// Addr is the node's IP address as observed by the manager
Addr string `protobuf:"bytes,3,opt,name=addr,proto3" json:"addr,omitempty"`
}
func (m *NodeStatus) Reset() { *m = NodeStatus{} }
func (*NodeStatus) ProtoMessage() {}
func (*NodeStatus) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{14} }
type Image struct {
// reference is a docker image reference. This can include a rpository, tag
// or be fully qualified witha digest. The format is specified in the
// distribution/reference package.
Reference string `protobuf:"bytes,1,opt,name=reference,proto3" json:"reference,omitempty"`
}
func (m *Image) Reset() { *m = Image{} }
func (*Image) ProtoMessage() {}
func (*Image) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{15} }
// Mount describes volume mounts for a container.
//
// The Mount type follows the structure of the mount syscall, including a type,
// source, target. Top-level flags, such as writable, are common to all kinds
// of mounts, where we also provide options that are specific to a type of
// mount. This corresponds to flags and data, respectively, in the syscall.
type Mount struct {
// Type defines the nature of the mount.
Type Mount_MountType `protobuf:"varint,1,opt,name=type,proto3,enum=docker.swarmkit.v1.Mount_MountType" json:"type,omitempty"`
// Source specifies the name of the mount. Depending on mount type, this
// may be a volume name or a host path, or even ignored.
Source string `protobuf:"bytes,2,opt,name=source,proto3" json:"source,omitempty"`
// Target path in container
Target string `protobuf:"bytes,3,opt,name=target,proto3" json:"target,omitempty"`
// ReadOnly should be set to true if the mount should not be writable.
ReadOnly bool `protobuf:"varint,4,opt,name=readonly,proto3" json:"readonly,omitempty"`
Consistency Mount_MountConsistency `protobuf:"varint,8,opt,name=consistency,proto3,enum=docker.swarmkit.v1.Mount_MountConsistency" json:"consistency,omitempty"`
// BindOptions configures properties of a bind mount type.
//
// For mounts of type bind, the source must be an absolute host path.
BindOptions *Mount_BindOptions `protobuf:"bytes,5,opt,name=bind_options,json=bindOptions" json:"bind_options,omitempty"`
// VolumeOptions configures the properties specific to a volume mount type.
//
// For mounts of type volume, the source will be used as the volume name.
VolumeOptions *Mount_VolumeOptions `protobuf:"bytes,6,opt,name=volume_options,json=volumeOptions" json:"volume_options,omitempty"`
// TmpfsOptions allows one to set options for mounting a temporary
// filesystem.
//
// The source field will be ignored when using mounts of type tmpfs.
TmpfsOptions *Mount_TmpfsOptions `protobuf:"bytes,7,opt,name=tmpfs_options,json=tmpfsOptions" json:"tmpfs_options,omitempty"`
}
func (m *Mount) Reset() { *m = Mount{} }
func (*Mount) ProtoMessage() {}
func (*Mount) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{16} }
// BindOptions specifies options that are specific to a bind mount.
type Mount_BindOptions struct {
// Propagation mode of mount.
Propagation Mount_BindOptions_MountPropagation `protobuf:"varint,1,opt,name=propagation,proto3,enum=docker.swarmkit.v1.Mount_BindOptions_MountPropagation" json:"propagation,omitempty"`
// allows non-recursive bind-mount, i.e. mount(2) with "bind" rather than "rbind".
NonRecursive bool `protobuf:"varint,2,opt,name=nonrecursive,proto3" json:"nonrecursive,omitempty"`
}
func (m *Mount_BindOptions) Reset() { *m = Mount_BindOptions{} }
func (*Mount_BindOptions) ProtoMessage() {}
func (*Mount_BindOptions) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{16, 0} }
// VolumeOptions contains parameters for mounting the volume.
type Mount_VolumeOptions struct {
// nocopy prevents automatic copying of data to the volume with data from target
NoCopy bool `protobuf:"varint,1,opt,name=nocopy,proto3" json:"nocopy,omitempty"`
// labels to apply to the volume if creating
Labels map[string]string `protobuf:"bytes,2,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
// DriverConfig specifies the options that may be passed to the driver
// if the volume is created.
//
// If this is empty, no volume will be created if the volume is missing.
DriverConfig *Driver `protobuf:"bytes,3,opt,name=driver_config,json=driverConfig" json:"driver_config,omitempty"`
}
func (m *Mount_VolumeOptions) Reset() { *m = Mount_VolumeOptions{} }
func (*Mount_VolumeOptions) ProtoMessage() {}
func (*Mount_VolumeOptions) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{16, 1} }
type Mount_TmpfsOptions struct {
// Size sets the size of the tmpfs, in bytes.
//
// This will be converted to an operating system specific value
// depending on the host. For example, on linux, it will be convered to
// use a 'k', 'm' or 'g' syntax. BSD, though not widely supported with
// docker, uses a straight byte value.
//
// Percentages are not supported.
SizeBytes int64 `protobuf:"varint,1,opt,name=size_bytes,json=sizeBytes,proto3" json:"size_bytes,omitempty"`
// Mode of the tmpfs upon creation