forked from kubernetes/kubernetes
-
Notifications
You must be signed in to change notification settings - Fork 0
/
api.pb.go
4052 lines (3612 loc) · 157 KB
/
api.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
/*
Copyright 2017 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Code generated by protoc-gen-gogo.
// source: api.proto
// DO NOT EDIT!
/*
Package runtime is a generated protocol buffer package.
It is generated from these files:
api.proto
It has these top-level messages:
VersionRequest
VersionResponse
DNSConfig
PortMapping
Mount
NamespaceOption
LinuxSandboxSecurityContext
LinuxPodSandboxConfig
PodSandboxMetadata
PodSandboxConfig
RunPodSandboxRequest
RunPodSandboxResponse
StopPodSandboxRequest
StopPodSandboxResponse
RemovePodSandboxRequest
RemovePodSandboxResponse
PodSandboxStatusRequest
PodSandboxNetworkStatus
Namespace
LinuxPodSandboxStatus
PodSandboxStatus
PodSandboxStatusResponse
PodSandboxFilter
ListPodSandboxRequest
PodSandbox
ListPodSandboxResponse
ImageSpec
KeyValue
LinuxContainerResources
SELinuxOption
Capability
LinuxContainerSecurityContext
LinuxContainerConfig
ContainerMetadata
Device
ContainerConfig
CreateContainerRequest
CreateContainerResponse
StartContainerRequest
StartContainerResponse
StopContainerRequest
StopContainerResponse
RemoveContainerRequest
RemoveContainerResponse
ContainerFilter
ListContainersRequest
Container
ListContainersResponse
ContainerStatusRequest
ContainerStatus
ContainerStatusResponse
ExecSyncRequest
ExecSyncResponse
ExecRequest
ExecResponse
AttachRequest
AttachResponse
PortForwardRequest
PortForwardResponse
ImageFilter
ListImagesRequest
Image
ListImagesResponse
ImageStatusRequest
ImageStatusResponse
AuthConfig
PullImageRequest
PullImageResponse
RemoveImageRequest
RemoveImageResponse
NetworkConfig
RuntimeConfig
UpdateRuntimeConfigRequest
UpdateRuntimeConfigResponse
RuntimeCondition
RuntimeStatus
StatusRequest
StatusResponse
*/
package runtime
import proto "github.com/gogo/protobuf/proto"
import fmt "fmt"
import math "math"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
const _ = proto.GoGoProtoPackageIsVersion1
type Protocol int32
const (
Protocol_TCP Protocol = 0
Protocol_UDP Protocol = 1
)
var Protocol_name = map[int32]string{
0: "TCP",
1: "UDP",
}
var Protocol_value = map[string]int32{
"TCP": 0,
"UDP": 1,
}
func (x Protocol) Enum() *Protocol {
p := new(Protocol)
*p = x
return p
}
func (x Protocol) String() string {
return proto.EnumName(Protocol_name, int32(x))
}
func (x *Protocol) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(Protocol_value, data, "Protocol")
if err != nil {
return err
}
*x = Protocol(value)
return nil
}
func (Protocol) EnumDescriptor() ([]byte, []int) { return fileDescriptorApi, []int{0} }
type PodSandboxState int32
const (
PodSandboxState_SANDBOX_READY PodSandboxState = 0
PodSandboxState_SANDBOX_NOTREADY PodSandboxState = 1
)
var PodSandboxState_name = map[int32]string{
0: "SANDBOX_READY",
1: "SANDBOX_NOTREADY",
}
var PodSandboxState_value = map[string]int32{
"SANDBOX_READY": 0,
"SANDBOX_NOTREADY": 1,
}
func (x PodSandboxState) Enum() *PodSandboxState {
p := new(PodSandboxState)
*p = x
return p
}
func (x PodSandboxState) String() string {
return proto.EnumName(PodSandboxState_name, int32(x))
}
func (x *PodSandboxState) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(PodSandboxState_value, data, "PodSandboxState")
if err != nil {
return err
}
*x = PodSandboxState(value)
return nil
}
func (PodSandboxState) EnumDescriptor() ([]byte, []int) { return fileDescriptorApi, []int{1} }
type ContainerState int32
const (
ContainerState_CONTAINER_CREATED ContainerState = 0
ContainerState_CONTAINER_RUNNING ContainerState = 1
ContainerState_CONTAINER_EXITED ContainerState = 2
ContainerState_CONTAINER_UNKNOWN ContainerState = 3
)
var ContainerState_name = map[int32]string{
0: "CONTAINER_CREATED",
1: "CONTAINER_RUNNING",
2: "CONTAINER_EXITED",
3: "CONTAINER_UNKNOWN",
}
var ContainerState_value = map[string]int32{
"CONTAINER_CREATED": 0,
"CONTAINER_RUNNING": 1,
"CONTAINER_EXITED": 2,
"CONTAINER_UNKNOWN": 3,
}
func (x ContainerState) Enum() *ContainerState {
p := new(ContainerState)
*p = x
return p
}
func (x ContainerState) String() string {
return proto.EnumName(ContainerState_name, int32(x))
}
func (x *ContainerState) UnmarshalJSON(data []byte) error {
value, err := proto.UnmarshalJSONEnum(ContainerState_value, data, "ContainerState")
if err != nil {
return err
}
*x = ContainerState(value)
return nil
}
func (ContainerState) EnumDescriptor() ([]byte, []int) { return fileDescriptorApi, []int{2} }
type VersionRequest struct {
// Version of the kubelet runtime API.
Version *string `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *VersionRequest) Reset() { *m = VersionRequest{} }
func (m *VersionRequest) String() string { return proto.CompactTextString(m) }
func (*VersionRequest) ProtoMessage() {}
func (*VersionRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{0} }
func (m *VersionRequest) GetVersion() string {
if m != nil && m.Version != nil {
return *m.Version
}
return ""
}
type VersionResponse struct {
// Version of the kubelet runtime API.
Version *string `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
// Name of the container runtime.
RuntimeName *string `protobuf:"bytes,2,opt,name=runtime_name,json=runtimeName" json:"runtime_name,omitempty"`
// Version of the container runtime. The string must be
// semver-compatible.
RuntimeVersion *string `protobuf:"bytes,3,opt,name=runtime_version,json=runtimeVersion" json:"runtime_version,omitempty"`
// API version of the container runtime. The string must be
// semver-compatible.
RuntimeApiVersion *string `protobuf:"bytes,4,opt,name=runtime_api_version,json=runtimeApiVersion" json:"runtime_api_version,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *VersionResponse) Reset() { *m = VersionResponse{} }
func (m *VersionResponse) String() string { return proto.CompactTextString(m) }
func (*VersionResponse) ProtoMessage() {}
func (*VersionResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{1} }
func (m *VersionResponse) GetVersion() string {
if m != nil && m.Version != nil {
return *m.Version
}
return ""
}
func (m *VersionResponse) GetRuntimeName() string {
if m != nil && m.RuntimeName != nil {
return *m.RuntimeName
}
return ""
}
func (m *VersionResponse) GetRuntimeVersion() string {
if m != nil && m.RuntimeVersion != nil {
return *m.RuntimeVersion
}
return ""
}
func (m *VersionResponse) GetRuntimeApiVersion() string {
if m != nil && m.RuntimeApiVersion != nil {
return *m.RuntimeApiVersion
}
return ""
}
// DNSConfig specifies the DNS servers and search domains of a sandbox.
type DNSConfig struct {
// List of DNS servers of the cluster.
Servers []string `protobuf:"bytes,1,rep,name=servers" json:"servers,omitempty"`
// List of DNS search domains of the cluster.
Searches []string `protobuf:"bytes,2,rep,name=searches" json:"searches,omitempty"`
// List of DNS options. See https://linux.die.net/man/5/resolv.conf
// for all available options.
Options []string `protobuf:"bytes,3,rep,name=options" json:"options,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *DNSConfig) Reset() { *m = DNSConfig{} }
func (m *DNSConfig) String() string { return proto.CompactTextString(m) }
func (*DNSConfig) ProtoMessage() {}
func (*DNSConfig) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{2} }
func (m *DNSConfig) GetServers() []string {
if m != nil {
return m.Servers
}
return nil
}
func (m *DNSConfig) GetSearches() []string {
if m != nil {
return m.Searches
}
return nil
}
func (m *DNSConfig) GetOptions() []string {
if m != nil {
return m.Options
}
return nil
}
// PortMapping specifies the port mapping configurations of a sandbox.
type PortMapping struct {
// Protocol of the port mapping.
Protocol *Protocol `protobuf:"varint,1,opt,name=protocol,enum=runtime.Protocol" json:"protocol,omitempty"`
// Port number within the container.
ContainerPort *int32 `protobuf:"varint,2,opt,name=container_port,json=containerPort" json:"container_port,omitempty"`
// Port number on the host.
HostPort *int32 `protobuf:"varint,3,opt,name=host_port,json=hostPort" json:"host_port,omitempty"`
// Host IP.
HostIp *string `protobuf:"bytes,4,opt,name=host_ip,json=hostIp" json:"host_ip,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PortMapping) Reset() { *m = PortMapping{} }
func (m *PortMapping) String() string { return proto.CompactTextString(m) }
func (*PortMapping) ProtoMessage() {}
func (*PortMapping) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{3} }
func (m *PortMapping) GetProtocol() Protocol {
if m != nil && m.Protocol != nil {
return *m.Protocol
}
return Protocol_TCP
}
func (m *PortMapping) GetContainerPort() int32 {
if m != nil && m.ContainerPort != nil {
return *m.ContainerPort
}
return 0
}
func (m *PortMapping) GetHostPort() int32 {
if m != nil && m.HostPort != nil {
return *m.HostPort
}
return 0
}
func (m *PortMapping) GetHostIp() string {
if m != nil && m.HostIp != nil {
return *m.HostIp
}
return ""
}
// Mount specifies a host volume to mount into a container.
type Mount struct {
// Path of the mount within the container.
ContainerPath *string `protobuf:"bytes,1,opt,name=container_path,json=containerPath" json:"container_path,omitempty"`
// Path of the mount on the host.
HostPath *string `protobuf:"bytes,2,opt,name=host_path,json=hostPath" json:"host_path,omitempty"`
// If set, the mount is read-only.
Readonly *bool `protobuf:"varint,3,opt,name=readonly" json:"readonly,omitempty"`
// If set, the mount needs SELinux relabeling.
SelinuxRelabel *bool `protobuf:"varint,4,opt,name=selinux_relabel,json=selinuxRelabel" json:"selinux_relabel,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *Mount) Reset() { *m = Mount{} }
func (m *Mount) String() string { return proto.CompactTextString(m) }
func (*Mount) ProtoMessage() {}
func (*Mount) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{4} }
func (m *Mount) GetContainerPath() string {
if m != nil && m.ContainerPath != nil {
return *m.ContainerPath
}
return ""
}
func (m *Mount) GetHostPath() string {
if m != nil && m.HostPath != nil {
return *m.HostPath
}
return ""
}
func (m *Mount) GetReadonly() bool {
if m != nil && m.Readonly != nil {
return *m.Readonly
}
return false
}
func (m *Mount) GetSelinuxRelabel() bool {
if m != nil && m.SelinuxRelabel != nil {
return *m.SelinuxRelabel
}
return false
}
// NamespaceOption provides options for Linux namespaces.
type NamespaceOption struct {
// If set, use the host's network namespace.
HostNetwork *bool `protobuf:"varint,1,opt,name=host_network,json=hostNetwork" json:"host_network,omitempty"`
// If set, use the host's PID namespace.
HostPid *bool `protobuf:"varint,2,opt,name=host_pid,json=hostPid" json:"host_pid,omitempty"`
// If set, use the host's IPC namespace.
HostIpc *bool `protobuf:"varint,3,opt,name=host_ipc,json=hostIpc" json:"host_ipc,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *NamespaceOption) Reset() { *m = NamespaceOption{} }
func (m *NamespaceOption) String() string { return proto.CompactTextString(m) }
func (*NamespaceOption) ProtoMessage() {}
func (*NamespaceOption) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{5} }
func (m *NamespaceOption) GetHostNetwork() bool {
if m != nil && m.HostNetwork != nil {
return *m.HostNetwork
}
return false
}
func (m *NamespaceOption) GetHostPid() bool {
if m != nil && m.HostPid != nil {
return *m.HostPid
}
return false
}
func (m *NamespaceOption) GetHostIpc() bool {
if m != nil && m.HostIpc != nil {
return *m.HostIpc
}
return false
}
// LinuxSandboxSecurityContext holds linux security configuration that will be
// applied to a sandbox. Note that:
// 1) It does not apply to containers in the pods.
// 2) It may not be applicable to a PodSandbox which does not contain any running
// process.
type LinuxSandboxSecurityContext struct {
// Configurations for the sandbox's namespaces.
// This will be used only if the PodSandbox uses namespace for isolation.
NamespaceOptions *NamespaceOption `protobuf:"bytes,1,opt,name=namespace_options,json=namespaceOptions" json:"namespace_options,omitempty"`
// Optional SELinux context to be applied.
SelinuxOptions *SELinuxOption `protobuf:"bytes,2,opt,name=selinux_options,json=selinuxOptions" json:"selinux_options,omitempty"`
// UID to run sandbox processes as, when applicable.
RunAsUser *int64 `protobuf:"varint,3,opt,name=run_as_user,json=runAsUser" json:"run_as_user,omitempty"`
// If set, the root filesystem of the sandbox is read-only.
ReadonlyRootfs *bool `protobuf:"varint,4,opt,name=readonly_rootfs,json=readonlyRootfs" json:"readonly_rootfs,omitempty"`
// List of groups applied to the first process run in the sandbox, in
// addition to the sandbox's primary GID.
SupplementalGroups []int64 `protobuf:"varint,5,rep,name=supplemental_groups,json=supplementalGroups" json:"supplemental_groups,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *LinuxSandboxSecurityContext) Reset() { *m = LinuxSandboxSecurityContext{} }
func (m *LinuxSandboxSecurityContext) String() string { return proto.CompactTextString(m) }
func (*LinuxSandboxSecurityContext) ProtoMessage() {}
func (*LinuxSandboxSecurityContext) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{6} }
func (m *LinuxSandboxSecurityContext) GetNamespaceOptions() *NamespaceOption {
if m != nil {
return m.NamespaceOptions
}
return nil
}
func (m *LinuxSandboxSecurityContext) GetSelinuxOptions() *SELinuxOption {
if m != nil {
return m.SelinuxOptions
}
return nil
}
func (m *LinuxSandboxSecurityContext) GetRunAsUser() int64 {
if m != nil && m.RunAsUser != nil {
return *m.RunAsUser
}
return 0
}
func (m *LinuxSandboxSecurityContext) GetReadonlyRootfs() bool {
if m != nil && m.ReadonlyRootfs != nil {
return *m.ReadonlyRootfs
}
return false
}
func (m *LinuxSandboxSecurityContext) GetSupplementalGroups() []int64 {
if m != nil {
return m.SupplementalGroups
}
return nil
}
// LinuxPodSandboxConfig holds platform-specific configurations for Linux
// host platforms and Linux-based containers.
type LinuxPodSandboxConfig struct {
// Parent cgroup of the PodSandbox.
// The cgroupfs style syntax will be used, but the container runtime can
// convert it to systemd semantics if needed.
CgroupParent *string `protobuf:"bytes,1,opt,name=cgroup_parent,json=cgroupParent" json:"cgroup_parent,omitempty"`
// LinuxSandboxSecurityContext holds sandbox security attributes.
SecurityContext *LinuxSandboxSecurityContext `protobuf:"bytes,2,opt,name=security_context,json=securityContext" json:"security_context,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *LinuxPodSandboxConfig) Reset() { *m = LinuxPodSandboxConfig{} }
func (m *LinuxPodSandboxConfig) String() string { return proto.CompactTextString(m) }
func (*LinuxPodSandboxConfig) ProtoMessage() {}
func (*LinuxPodSandboxConfig) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{7} }
func (m *LinuxPodSandboxConfig) GetCgroupParent() string {
if m != nil && m.CgroupParent != nil {
return *m.CgroupParent
}
return ""
}
func (m *LinuxPodSandboxConfig) GetSecurityContext() *LinuxSandboxSecurityContext {
if m != nil {
return m.SecurityContext
}
return nil
}
// PodSandboxMetadata holds all necessary information for building the sandbox name.
// The container runtime is encouraged to expose the metadata associated with the
// PodSandbox in its user interface for better user experience. For example,
// the runtime can construct a unique PodSandboxName based on the metadata.
type PodSandboxMetadata struct {
// Pod name of the sandbox. Same as the pod name in the PodSpec.
Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// Pod UID of the sandbox. Same as the pod UID in the PodSpec.
Uid *string `protobuf:"bytes,2,opt,name=uid" json:"uid,omitempty"`
// Pod namespace of the sandbox. Same as the pod namespace in the PodSpec.
Namespace *string `protobuf:"bytes,3,opt,name=namespace" json:"namespace,omitempty"`
// Attempt number of creating the sandbox.
Attempt *uint32 `protobuf:"varint,4,opt,name=attempt" json:"attempt,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PodSandboxMetadata) Reset() { *m = PodSandboxMetadata{} }
func (m *PodSandboxMetadata) String() string { return proto.CompactTextString(m) }
func (*PodSandboxMetadata) ProtoMessage() {}
func (*PodSandboxMetadata) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{8} }
func (m *PodSandboxMetadata) GetName() string {
if m != nil && m.Name != nil {
return *m.Name
}
return ""
}
func (m *PodSandboxMetadata) GetUid() string {
if m != nil && m.Uid != nil {
return *m.Uid
}
return ""
}
func (m *PodSandboxMetadata) GetNamespace() string {
if m != nil && m.Namespace != nil {
return *m.Namespace
}
return ""
}
func (m *PodSandboxMetadata) GetAttempt() uint32 {
if m != nil && m.Attempt != nil {
return *m.Attempt
}
return 0
}
// PodSandboxConfig holds all the required and optional fields for creating a
// sandbox.
type PodSandboxConfig struct {
// Metadata of the sandbox. This information will uniquely identify the
// sandbox, and the runtime should leverage this to ensure correct
// operation. The runtime may also use this information to improve UX, such
// as by constructing a readable name.
Metadata *PodSandboxMetadata `protobuf:"bytes,1,opt,name=metadata" json:"metadata,omitempty"`
// Hostname of the sandbox.
Hostname *string `protobuf:"bytes,2,opt,name=hostname" json:"hostname,omitempty"`
// Path to the directory on the host in which container log files are
// stored.
// By default the log of a container going into the LogDirectory will be
// hooked up to STDOUT and STDERR. However, the LogDirectory may contain
// binary log files with structured logging data from the individual
// containers. For example, the files might be newline separated JSON
// structured logs, systemd-journald journal files, gRPC trace files, etc.
// E.g.,
// PodSandboxConfig.LogDirectory = `/var/log/pods/<podUID>/`
// ContainerConfig.LogPath = `containerName_Instance#.log`
//
// WARNING: Log management and how kubelet should interface with the
// container logs are under active discussion in
// https://issues.k8s.io/24677. There *may* be future change of direction
// for logging as the discussion carries on.
LogDirectory *string `protobuf:"bytes,3,opt,name=log_directory,json=logDirectory" json:"log_directory,omitempty"`
// DNS config for the sandbox.
DnsConfig *DNSConfig `protobuf:"bytes,4,opt,name=dns_config,json=dnsConfig" json:"dns_config,omitempty"`
// Port mappings for the sandbox.
PortMappings []*PortMapping `protobuf:"bytes,5,rep,name=port_mappings,json=portMappings" json:"port_mappings,omitempty"`
// Key-value pairs that may be used to scope and select individual resources.
Labels map[string]string `protobuf:"bytes,6,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
// Annotations is an unstructured key value map that may be set by external
// tools to store and retrieve arbitrary metadata. There are a few features are
// driven by annotations, Runtimes could support them optionally:
//
// 1. AppArmor
//
// key: container.apparmor.security.beta.kubernetes.io/<container_name>
// description: apparmor profile for the container.
// value:
// * runtime/default: equivalent to not specifying a profile.
// * localhost/<profile_name>: profile loaded on the node
// (localhost) by name. The possible profile names are detailed at
// http://wiki.apparmor.net/index.php/AppArmor_Core_Policy_Reference
//
// 2. Seccomp
//
// key: security.alpha.kubernetes.io/seccomp/pod
// description: the seccomp profile for the containers of an entire pod.
// value: see below.
//
// key: security.alpha.kubernetes.io/seccomp/container/<container name>
// description: the seccomp profile for the container (overides pod).
// values: see below
//
// The value of seccomp is runtime agnostic:
// * runtime/default: the default profile for the container runtime
// * unconfined: unconfined profile, ie, no seccomp sandboxing
// * localhost/<profile-name>: the profile installed to the node's
// local seccomp profile root. Note that profile root is set in
// kubelet, and it is not passed in CRI yet, see https://issues.k8s.io/36997.
//
// 3. Sysctls
//
// key: security.alpha.kubernetes.io/sysctls
// description: list of safe sysctls which are set for the sandbox.
// value: comma separated list of sysctl_name=value key-value pairs.
//
// key: security.alpha.kubernetes.io/unsafe-sysctls
// description: list of unsafe sysctls which are set for the sandbox.
// value: comma separated list of sysctl_name=value key-value pairs.
//
Annotations map[string]string `protobuf:"bytes,7,rep,name=annotations" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
// Optional configurations specific to Linux hosts.
Linux *LinuxPodSandboxConfig `protobuf:"bytes,8,opt,name=linux" json:"linux,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PodSandboxConfig) Reset() { *m = PodSandboxConfig{} }
func (m *PodSandboxConfig) String() string { return proto.CompactTextString(m) }
func (*PodSandboxConfig) ProtoMessage() {}
func (*PodSandboxConfig) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{9} }
func (m *PodSandboxConfig) GetMetadata() *PodSandboxMetadata {
if m != nil {
return m.Metadata
}
return nil
}
func (m *PodSandboxConfig) GetHostname() string {
if m != nil && m.Hostname != nil {
return *m.Hostname
}
return ""
}
func (m *PodSandboxConfig) GetLogDirectory() string {
if m != nil && m.LogDirectory != nil {
return *m.LogDirectory
}
return ""
}
func (m *PodSandboxConfig) GetDnsConfig() *DNSConfig {
if m != nil {
return m.DnsConfig
}
return nil
}
func (m *PodSandboxConfig) GetPortMappings() []*PortMapping {
if m != nil {
return m.PortMappings
}
return nil
}
func (m *PodSandboxConfig) GetLabels() map[string]string {
if m != nil {
return m.Labels
}
return nil
}
func (m *PodSandboxConfig) GetAnnotations() map[string]string {
if m != nil {
return m.Annotations
}
return nil
}
func (m *PodSandboxConfig) GetLinux() *LinuxPodSandboxConfig {
if m != nil {
return m.Linux
}
return nil
}
type RunPodSandboxRequest struct {
// Configuration for creating a PodSandbox.
Config *PodSandboxConfig `protobuf:"bytes,1,opt,name=config" json:"config,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *RunPodSandboxRequest) Reset() { *m = RunPodSandboxRequest{} }
func (m *RunPodSandboxRequest) String() string { return proto.CompactTextString(m) }
func (*RunPodSandboxRequest) ProtoMessage() {}
func (*RunPodSandboxRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{10} }
func (m *RunPodSandboxRequest) GetConfig() *PodSandboxConfig {
if m != nil {
return m.Config
}
return nil
}
type RunPodSandboxResponse struct {
// ID of the PodSandbox to run.
PodSandboxId *string `protobuf:"bytes,1,opt,name=pod_sandbox_id,json=podSandboxId" json:"pod_sandbox_id,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *RunPodSandboxResponse) Reset() { *m = RunPodSandboxResponse{} }
func (m *RunPodSandboxResponse) String() string { return proto.CompactTextString(m) }
func (*RunPodSandboxResponse) ProtoMessage() {}
func (*RunPodSandboxResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{11} }
func (m *RunPodSandboxResponse) GetPodSandboxId() string {
if m != nil && m.PodSandboxId != nil {
return *m.PodSandboxId
}
return ""
}
type StopPodSandboxRequest struct {
// ID of the PodSandbox to stop.
PodSandboxId *string `protobuf:"bytes,1,opt,name=pod_sandbox_id,json=podSandboxId" json:"pod_sandbox_id,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *StopPodSandboxRequest) Reset() { *m = StopPodSandboxRequest{} }
func (m *StopPodSandboxRequest) String() string { return proto.CompactTextString(m) }
func (*StopPodSandboxRequest) ProtoMessage() {}
func (*StopPodSandboxRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{12} }
func (m *StopPodSandboxRequest) GetPodSandboxId() string {
if m != nil && m.PodSandboxId != nil {
return *m.PodSandboxId
}
return ""
}
type StopPodSandboxResponse struct {
XXX_unrecognized []byte `json:"-"`
}
func (m *StopPodSandboxResponse) Reset() { *m = StopPodSandboxResponse{} }
func (m *StopPodSandboxResponse) String() string { return proto.CompactTextString(m) }
func (*StopPodSandboxResponse) ProtoMessage() {}
func (*StopPodSandboxResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{13} }
type RemovePodSandboxRequest struct {
// ID of the PodSandbox to remove.
PodSandboxId *string `protobuf:"bytes,1,opt,name=pod_sandbox_id,json=podSandboxId" json:"pod_sandbox_id,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *RemovePodSandboxRequest) Reset() { *m = RemovePodSandboxRequest{} }
func (m *RemovePodSandboxRequest) String() string { return proto.CompactTextString(m) }
func (*RemovePodSandboxRequest) ProtoMessage() {}
func (*RemovePodSandboxRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{14} }
func (m *RemovePodSandboxRequest) GetPodSandboxId() string {
if m != nil && m.PodSandboxId != nil {
return *m.PodSandboxId
}
return ""
}
type RemovePodSandboxResponse struct {
XXX_unrecognized []byte `json:"-"`
}
func (m *RemovePodSandboxResponse) Reset() { *m = RemovePodSandboxResponse{} }
func (m *RemovePodSandboxResponse) String() string { return proto.CompactTextString(m) }
func (*RemovePodSandboxResponse) ProtoMessage() {}
func (*RemovePodSandboxResponse) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{15} }
type PodSandboxStatusRequest struct {
// ID of the PodSandbox for which to retrieve status.
PodSandboxId *string `protobuf:"bytes,1,opt,name=pod_sandbox_id,json=podSandboxId" json:"pod_sandbox_id,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PodSandboxStatusRequest) Reset() { *m = PodSandboxStatusRequest{} }
func (m *PodSandboxStatusRequest) String() string { return proto.CompactTextString(m) }
func (*PodSandboxStatusRequest) ProtoMessage() {}
func (*PodSandboxStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{16} }
func (m *PodSandboxStatusRequest) GetPodSandboxId() string {
if m != nil && m.PodSandboxId != nil {
return *m.PodSandboxId
}
return ""
}
// PodSandboxNetworkStatus is the status of the network for a PodSandbox.
type PodSandboxNetworkStatus struct {
// IP address of the PodSandbox.
Ip *string `protobuf:"bytes,1,opt,name=ip" json:"ip,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PodSandboxNetworkStatus) Reset() { *m = PodSandboxNetworkStatus{} }
func (m *PodSandboxNetworkStatus) String() string { return proto.CompactTextString(m) }
func (*PodSandboxNetworkStatus) ProtoMessage() {}
func (*PodSandboxNetworkStatus) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{17} }
func (m *PodSandboxNetworkStatus) GetIp() string {
if m != nil && m.Ip != nil {
return *m.Ip
}
return ""
}
// Namespace contains paths to the namespaces.
type Namespace struct {
// Path to the network namespace.
Network *string `protobuf:"bytes,1,opt,name=network" json:"network,omitempty"`
// Namespace options for Linux namespaces.
Options *NamespaceOption `protobuf:"bytes,2,opt,name=options" json:"options,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *Namespace) Reset() { *m = Namespace{} }
func (m *Namespace) String() string { return proto.CompactTextString(m) }
func (*Namespace) ProtoMessage() {}
func (*Namespace) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{18} }
func (m *Namespace) GetNetwork() string {
if m != nil && m.Network != nil {
return *m.Network
}
return ""
}
func (m *Namespace) GetOptions() *NamespaceOption {
if m != nil {
return m.Options
}
return nil
}
// LinuxSandboxStatus contains status specific to Linux sandboxes.
type LinuxPodSandboxStatus struct {
// Paths to the sandbox's namespaces.
Namespaces *Namespace `protobuf:"bytes,1,opt,name=namespaces" json:"namespaces,omitempty"`
XXX_unrecognized []byte `json:"-"`
}
func (m *LinuxPodSandboxStatus) Reset() { *m = LinuxPodSandboxStatus{} }
func (m *LinuxPodSandboxStatus) String() string { return proto.CompactTextString(m) }
func (*LinuxPodSandboxStatus) ProtoMessage() {}
func (*LinuxPodSandboxStatus) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{19} }
func (m *LinuxPodSandboxStatus) GetNamespaces() *Namespace {
if m != nil {
return m.Namespaces
}
return nil
}
// PodSandboxStatus contains the status of the PodSandbox.
type PodSandboxStatus struct {
// ID of the sandbox.
Id *string `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
// Metadata of the sandbox.
Metadata *PodSandboxMetadata `protobuf:"bytes,2,opt,name=metadata" json:"metadata,omitempty"`
// State of the sandbox.
State *PodSandboxState `protobuf:"varint,3,opt,name=state,enum=runtime.PodSandboxState" json:"state,omitempty"`
// Creation timestamp of the sandbox in nanoseconds.
CreatedAt *int64 `protobuf:"varint,4,opt,name=created_at,json=createdAt" json:"created_at,omitempty"`
// Network contains network status if network is handled by the runtime.
Network *PodSandboxNetworkStatus `protobuf:"bytes,5,opt,name=network" json:"network,omitempty"`
// Linux-specific status to a pod sandbox.
Linux *LinuxPodSandboxStatus `protobuf:"bytes,6,opt,name=linux" json:"linux,omitempty"`
// Labels are key value pairs that may be used to scope and select individual resources.
Labels map[string]string `protobuf:"bytes,7,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
// Annotations is an unstructured key value map that may be set by external
// tools to store and retrieve arbitrary metadata.
Annotations map[string]string `protobuf:"bytes,8,rep,name=annotations" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
XXX_unrecognized []byte `json:"-"`
}
func (m *PodSandboxStatus) Reset() { *m = PodSandboxStatus{} }
func (m *PodSandboxStatus) String() string { return proto.CompactTextString(m) }
func (*PodSandboxStatus) ProtoMessage() {}
func (*PodSandboxStatus) Descriptor() ([]byte, []int) { return fileDescriptorApi, []int{20} }
func (m *PodSandboxStatus) GetId() string {
if m != nil && m.Id != nil {
return *m.Id
}
return ""
}
func (m *PodSandboxStatus) GetMetadata() *PodSandboxMetadata {
if m != nil {
return m.Metadata
}
return nil
}
func (m *PodSandboxStatus) GetState() PodSandboxState {
if m != nil && m.State != nil {
return *m.State
}
return PodSandboxState_SANDBOX_READY
}
func (m *PodSandboxStatus) GetCreatedAt() int64 {
if m != nil && m.CreatedAt != nil {
return *m.CreatedAt
}
return 0
}
func (m *PodSandboxStatus) GetNetwork() *PodSandboxNetworkStatus {
if m != nil {
return m.Network
}
return nil
}
func (m *PodSandboxStatus) GetLinux() *LinuxPodSandboxStatus {
if m != nil {
return m.Linux
}
return nil
}
func (m *PodSandboxStatus) GetLabels() map[string]string {
if m != nil {
return m.Labels
}
return nil
}
func (m *PodSandboxStatus) GetAnnotations() map[string]string {
if m != nil {
return m.Annotations