// things that are allowed to see the host machine. Most containers will NOT need this.
// things that are allowed to see the host machine. Most containers will NOT need this.
// TODO(jonesdl) We need to restrict who can use host directory mounts and
// TODO(jonesdl) We need to restrict who can use host directory mounts and
// who can/can not mount host directories as read/write.
// who can/can not mount host directories as read/write.
HostDir*HostPath`json:"hostDir" description:"pre-existing host file or directory; generally for privileged system daemons or other agents tied to the host"`
HostDir*HostPathVolumeSource`json:"hostDir" description:"pre-existing host file or directory; generally for privileged system daemons or other agents tied to the host"`
// EmptyDir represents a temporary directory that shares a pod's lifetime.
// EmptyDir represents a temporary directory that shares a pod's lifetime.
EmptyDir*EmptyDir`json:"emptyDir" description:"temporary directory that shares a pod's lifetime"`
EmptyDir*EmptyDirVolumeSource`json:"emptyDir" description:"temporary directory that shares a pod's lifetime"`
// GCEPersistentDisk represents a GCE Disk resource that is attached to a
// GCEPersistentDisk represents a GCE Disk resource that is attached to a
// kubelet's host machine and then exposed to the pod.
// kubelet's host machine and then exposed to the pod.
GCEPersistentDisk*GCEPersistentDisk`json:"persistentDisk" description:"GCE disk resource attached to the host machine on demand"`
GCEPersistentDisk*GCEPersistentDiskVolumeSource`json:"persistentDisk" description:"GCE disk resource attached to the host machine on demand"`
// GitRepo represents a git repository at a particular revision.
// GitRepo represents a git repository at a particular revision.
GitRepo*GitRepo`json:"gitRepo" description:"git repository at a particular revision"`
GitRepo*GitRepoVolumeSource`json:"gitRepo" description:"git repository at a particular revision"`
// Secret represents a secret to populate the volume with
// Secret represents a secret to populate the volume with
Secret*SecretSource`json:"secret" description:"secret to populate volume with"`
Secret*SecretVolumeSource`json:"secret" description:"secret to populate volume with"`
}
}
// HostPath represents bare host directory volume.
// HostPathVolumeSource represents bare host directory volume.
typeHostPathstruct{
typeHostPathVolumeSourcestruct{
Pathstring`json:"path" description:"path of the directory on the host"`
Pathstring`json:"path" description:"path of the directory on the host"`
}
}
typeEmptyDirstruct{}
typeEmptyDirVolumeSourcestruct{}
// Protocol defines network protocols supported for things like conatiner ports.
// Protocol defines network protocols supported for things like conatiner ports.
typeProtocolstring
typeProtocolstring
...
@@ -124,12 +124,12 @@ const (
...
@@ -124,12 +124,12 @@ const (
ProtocolUDPProtocol="UDP"
ProtocolUDPProtocol="UDP"
)
)
// GCEPersistentDisk represents a Persistent Disk resource in Google Compute Engine.
// GCEPersistentDiskVolumeSource represents a Persistent Disk resource in Google Compute Engine.
//
//
// A GCE PD must exist and be formatted before mounting to a container.
// A GCE PD must exist and be formatted before mounting to a container.
// The disk must also be in the same GCE project and zone as the kubelet.
// The disk must also be in the same GCE project and zone as the kubelet.
// A GCE PD can only be mounted as read/write once.
// A GCE PD can only be mounted as read/write once.
typeGCEPersistentDiskstruct{
typeGCEPersistentDiskVolumeSourcestruct{
// Unique name of the PD resource. Used to identify the disk in GCE
// Unique name of the PD resource. Used to identify the disk in GCE
PDNamestring`json:"pdName" description:"unique name of the PD resource in GCE"`
PDNamestring`json:"pdName" description:"unique name of the PD resource in GCE"`
// Required: Filesystem type to mount.
// Required: Filesystem type to mount.
...
@@ -147,16 +147,16 @@ type GCEPersistentDisk struct {
...
@@ -147,16 +147,16 @@ type GCEPersistentDisk struct {
ReadOnlybool`json:"readOnly,omitempty" description:"read-only if true, read-write otherwise (false or unspecified)"`
ReadOnlybool`json:"readOnly,omitempty" description:"read-only if true, read-write otherwise (false or unspecified)"`
}
}
// GitRepo represents a volume that is pulled from git when the pod is created.
// GitRepoVolumeSource represents a volume that is pulled from git when the pod is created.
// things that are allowed to see the host machine. Most containers will NOT need this.
// things that are allowed to see the host machine. Most containers will NOT need this.
// TODO(jonesdl) We need to restrict who can use host directory mounts and
// TODO(jonesdl) We need to restrict who can use host directory mounts and
// who can/can not mount host directories as read/write.
// who can/can not mount host directories as read/write.
HostDir*HostPath`json:"hostDir" description:"pre-existing host file or directory; generally for privileged system daemons or other agents tied to the host"`
HostDir*HostPathVolumeSource`json:"hostDir" description:"pre-existing host file or directory; generally for privileged system daemons or other agents tied to the host"`
// EmptyDir represents a temporary directory that shares a pod's lifetime.
// EmptyDir represents a temporary directory that shares a pod's lifetime.
EmptyDir*EmptyDir`json:"emptyDir" description:"temporary directory that shares a pod's lifetime"`
EmptyDir*EmptyDirVolumeSource`json:"emptyDir" description:"temporary directory that shares a pod's lifetime"`
// A persistent disk that is mounted to the
// A persistent disk that is mounted to the
// kubelet's host machine and then exposed to the pod.
// kubelet's host machine and then exposed to the pod.
GCEPersistentDisk*GCEPersistentDisk`json:"persistentDisk" description:"GCE disk resource attached to the host machine on demand"`
GCEPersistentDisk*GCEPersistentDiskVolumeSource`json:"persistentDisk" description:"GCE disk resource attached to the host machine on demand"`
// GitRepo represents a git repository at a particular revision.
// GitRepo represents a git repository at a particular revision.
GitRepo*GitRepo`json:"gitRepo" description:"git repository at a particular revision"`
GitRepo*GitRepoVolumeSource`json:"gitRepo" description:"git repository at a particular revision"`
// Secret is a secret to populate the volume with
// Secret is a secret to populate the volume with
Secret*SecretSource`json:"secret" description:"secret to populate volume"`
Secret*SecretVolumeSource`json:"secret" description:"secret to populate volume"`
}
}
// HostPath represents bare host directory volume.
// HostPathVolumeSource represents bare host directory volume.
typeHostPathstruct{
typeHostPathVolumeSourcestruct{
Pathstring`json:"path" description:"path of the directory on the host"`
Pathstring`json:"path" description:"path of the directory on the host"`
}
}
typeEmptyDirstruct{}
typeEmptyDirVolumeSourcestruct{}
// Adapts a Secret into a VolumeSource
// SecretVolumeSource adapts a Secret into a VolumeSource
typeSecretSourcestruct{
typeSecretVolumeSourcestruct{
// Reference to a Secret
// Reference to a Secret
TargetObjectReference`json:"target" description:"target is a reference to a secret"`
TargetObjectReference`json:"target" description:"target is a reference to a secret"`
}
}
...
@@ -114,12 +114,12 @@ type Port struct {
...
@@ -114,12 +114,12 @@ type Port struct {
HostIPstring`json:"hostIP,omitempty" description:"host IP to bind the port to"`
HostIPstring`json:"hostIP,omitempty" description:"host IP to bind the port to"`
}
}
// GCEPersistentDisk represents a Persistent Disk resource in Google Compute Engine.
// GCEPersistentDiskVolumeSource represents a Persistent Disk resource in Google Compute Engine.
//
//
// A GCE PD must exist and be formatted before mounting to a container.
// A GCE PD must exist and be formatted before mounting to a container.
// The disk must also be in the same GCE project and zone as the kubelet.
// The disk must also be in the same GCE project and zone as the kubelet.
// A GCE PD can only be mounted as read/write once.
// A GCE PD can only be mounted as read/write once.
typeGCEPersistentDiskstruct{
typeGCEPersistentDiskVolumeSourcestruct{
// Unique name of the PD resource. Used to identify the disk in GCE
// Unique name of the PD resource. Used to identify the disk in GCE
PDNamestring`json:"pdName" description:"unique name of the PD resource in GCE"`
PDNamestring`json:"pdName" description:"unique name of the PD resource in GCE"`
// Required: Filesystem type to mount.
// Required: Filesystem type to mount.
...
@@ -137,8 +137,8 @@ type GCEPersistentDisk struct {
...
@@ -137,8 +137,8 @@ type GCEPersistentDisk struct {
ReadOnlybool`json:"readOnly,omitempty" description:"read-only if true, read-write otherwise (false or unspecified)"`
ReadOnlybool`json:"readOnly,omitempty" description:"read-only if true, read-write otherwise (false or unspecified)"`
}
}
// GitRepo represents a volume that is pulled from git when the pod is created.
// GitRepoVolumeSource represents a volume that is pulled from git when the pod is created.