Merge pull request #125600 from thockin/plus_default_deprecated_volumes
Use +default for deprecated volume types
This commit is contained in:
@@ -313,6 +313,7 @@
|
||||
"description": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.",
|
||||
"properties": {
|
||||
"cachingMode": {
|
||||
"default": "ReadWrite",
|
||||
"description": "cachingMode is the Host Caching mode: None, Read Only, Read Write.",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -327,14 +328,17 @@
|
||||
"type": "string"
|
||||
},
|
||||
"fsType": {
|
||||
"default": "ext4",
|
||||
"description": "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
|
||||
"type": "string"
|
||||
},
|
||||
"kind": {
|
||||
"default": "Shared",
|
||||
"description": "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared",
|
||||
"type": "string"
|
||||
},
|
||||
"readOnly": {
|
||||
"default": false,
|
||||
"description": "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
|
||||
"type": "boolean"
|
||||
}
|
||||
@@ -2873,6 +2877,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"iscsiInterface": {
|
||||
"default": "default",
|
||||
"description": "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -2941,6 +2946,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"iscsiInterface": {
|
||||
"default": "default",
|
||||
"description": "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6206,6 +6212,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"keyring": {
|
||||
"default": "/etc/ceph/keyring",
|
||||
"description": "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6219,6 +6226,7 @@
|
||||
"x-kubernetes-list-type": "atomic"
|
||||
},
|
||||
"pool": {
|
||||
"default": "rbd",
|
||||
"description": "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6235,6 +6243,7 @@
|
||||
"description": "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it"
|
||||
},
|
||||
"user": {
|
||||
"default": "admin",
|
||||
"description": "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
}
|
||||
@@ -6258,6 +6267,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"keyring": {
|
||||
"default": "/etc/ceph/keyring",
|
||||
"description": "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6271,6 +6281,7 @@
|
||||
"x-kubernetes-list-type": "atomic"
|
||||
},
|
||||
"pool": {
|
||||
"default": "rbd",
|
||||
"description": "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6287,6 +6298,7 @@
|
||||
"description": "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it"
|
||||
},
|
||||
"user": {
|
||||
"default": "admin",
|
||||
"description": "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
}
|
||||
@@ -6758,6 +6770,7 @@
|
||||
"description": "ScaleIOPersistentVolumeSource represents a persistent ScaleIO volume",
|
||||
"properties": {
|
||||
"fsType": {
|
||||
"default": "xfs",
|
||||
"description": "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\"",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6787,6 +6800,7 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"storageMode": {
|
||||
"default": "ThinProvisioned",
|
||||
"description": "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6815,6 +6829,7 @@
|
||||
"description": "ScaleIOVolumeSource represents a persistent ScaleIO volume",
|
||||
"properties": {
|
||||
"fsType": {
|
||||
"default": "xfs",
|
||||
"description": "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -6844,6 +6859,7 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"storageMode": {
|
||||
"default": "ThinProvisioned",
|
||||
"description": "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
@@ -1421,6 +1421,7 @@
|
||||
"description": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.",
|
||||
"properties": {
|
||||
"cachingMode": {
|
||||
"default": "ReadWrite",
|
||||
"description": "cachingMode is the Host Caching mode: None, Read Only, Read Write.",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -1435,14 +1436,17 @@
|
||||
"type": "string"
|
||||
},
|
||||
"fsType": {
|
||||
"default": "ext4",
|
||||
"description": "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
|
||||
"type": "string"
|
||||
},
|
||||
"kind": {
|
||||
"default": "Shared",
|
||||
"description": "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared",
|
||||
"type": "string"
|
||||
},
|
||||
"readOnly": {
|
||||
"default": false,
|
||||
"description": "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
|
||||
"type": "boolean"
|
||||
}
|
||||
@@ -2772,6 +2776,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"iscsiInterface": {
|
||||
"default": "default",
|
||||
"description": "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -4247,6 +4252,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"keyring": {
|
||||
"default": "/etc/ceph/keyring",
|
||||
"description": "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -4260,6 +4266,7 @@
|
||||
"x-kubernetes-list-type": "atomic"
|
||||
},
|
||||
"pool": {
|
||||
"default": "rbd",
|
||||
"description": "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -4276,6 +4283,7 @@
|
||||
"description": "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it"
|
||||
},
|
||||
"user": {
|
||||
"default": "admin",
|
||||
"description": "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
}
|
||||
@@ -4389,6 +4397,7 @@
|
||||
"description": "ScaleIOVolumeSource represents a persistent ScaleIO volume",
|
||||
"properties": {
|
||||
"fsType": {
|
||||
"default": "xfs",
|
||||
"description": "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -4418,6 +4427,7 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"storageMode": {
|
||||
"default": "ThinProvisioned",
|
||||
"description": "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
@@ -770,6 +770,7 @@
|
||||
"description": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.",
|
||||
"properties": {
|
||||
"cachingMode": {
|
||||
"default": "ReadWrite",
|
||||
"description": "cachingMode is the Host Caching mode: None, Read Only, Read Write.",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -784,14 +785,17 @@
|
||||
"type": "string"
|
||||
},
|
||||
"fsType": {
|
||||
"default": "ext4",
|
||||
"description": "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
|
||||
"type": "string"
|
||||
},
|
||||
"kind": {
|
||||
"default": "Shared",
|
||||
"description": "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared",
|
||||
"type": "string"
|
||||
},
|
||||
"readOnly": {
|
||||
"default": false,
|
||||
"description": "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
|
||||
"type": "boolean"
|
||||
}
|
||||
@@ -2121,6 +2125,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"iscsiInterface": {
|
||||
"default": "default",
|
||||
"description": "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -3451,6 +3456,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"keyring": {
|
||||
"default": "/etc/ceph/keyring",
|
||||
"description": "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -3464,6 +3470,7 @@
|
||||
"x-kubernetes-list-type": "atomic"
|
||||
},
|
||||
"pool": {
|
||||
"default": "rbd",
|
||||
"description": "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -3480,6 +3487,7 @@
|
||||
"description": "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it"
|
||||
},
|
||||
"user": {
|
||||
"default": "admin",
|
||||
"description": "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
}
|
||||
@@ -3593,6 +3601,7 @@
|
||||
"description": "ScaleIOVolumeSource represents a persistent ScaleIO volume",
|
||||
"properties": {
|
||||
"fsType": {
|
||||
"default": "xfs",
|
||||
"description": "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -3622,6 +3631,7 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"storageMode": {
|
||||
"default": "ThinProvisioned",
|
||||
"description": "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
"description": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.",
|
||||
"properties": {
|
||||
"cachingMode": {
|
||||
"default": "ReadWrite",
|
||||
"description": "cachingMode is the Host Caching mode: None, Read Only, Read Write.",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -46,14 +47,17 @@
|
||||
"type": "string"
|
||||
},
|
||||
"fsType": {
|
||||
"default": "ext4",
|
||||
"description": "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
|
||||
"type": "string"
|
||||
},
|
||||
"kind": {
|
||||
"default": "Shared",
|
||||
"description": "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared",
|
||||
"type": "string"
|
||||
},
|
||||
"readOnly": {
|
||||
"default": false,
|
||||
"description": "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
|
||||
"type": "boolean"
|
||||
}
|
||||
@@ -427,6 +431,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"iscsiInterface": {
|
||||
"default": "default",
|
||||
"description": "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -961,6 +966,7 @@
|
||||
"type": "string"
|
||||
},
|
||||
"keyring": {
|
||||
"default": "/etc/ceph/keyring",
|
||||
"description": "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -974,6 +980,7 @@
|
||||
"x-kubernetes-list-type": "atomic"
|
||||
},
|
||||
"pool": {
|
||||
"default": "rbd",
|
||||
"description": "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -990,6 +997,7 @@
|
||||
"description": "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it"
|
||||
},
|
||||
"user": {
|
||||
"default": "admin",
|
||||
"description": "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
"type": "string"
|
||||
}
|
||||
@@ -1004,6 +1012,7 @@
|
||||
"description": "ScaleIOPersistentVolumeSource represents a persistent ScaleIO volume",
|
||||
"properties": {
|
||||
"fsType": {
|
||||
"default": "xfs",
|
||||
"description": "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\"",
|
||||
"type": "string"
|
||||
},
|
||||
@@ -1033,6 +1042,7 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"storageMode": {
|
||||
"default": "ThinProvisioned",
|
||||
"description": "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
567
pkg/apis/apps/v1/zz_generated.defaults.go
generated
567
pkg/apis/apps/v1/zz_generated.defaults.go
generated
File diff suppressed because it is too large
Load Diff
291
pkg/apis/apps/v1beta1/zz_generated.defaults.go
generated
291
pkg/apis/apps/v1beta1/zz_generated.defaults.go
generated
@@ -23,8 +23,9 @@ package v1beta1
|
||||
|
||||
import (
|
||||
v1beta1 "k8s.io/api/apps/v1beta1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
v1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -40,68 +41,98 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
|
||||
|
||||
func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
SetDefaults_Deployment(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -112,16 +143,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -131,9 +162,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -143,9 +174,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -157,19 +188,19 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -180,16 +211,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -199,9 +230,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -211,9 +242,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -225,19 +256,19 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -248,16 +279,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -267,9 +298,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -279,9 +310,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -293,17 +324,17 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_DeploymentList(in *v1beta1.DeploymentList) {
|
||||
@@ -315,68 +346,98 @@ func SetObjectDefaults_DeploymentList(in *v1beta1.DeploymentList) {
|
||||
|
||||
func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
SetDefaults_StatefulSet(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -387,16 +448,16 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -406,9 +467,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -418,9 +479,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -432,19 +493,19 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -455,16 +516,16 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -474,9 +535,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -486,9 +547,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -500,19 +561,19 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -523,16 +584,16 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -542,9 +603,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -554,9 +615,9 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -568,25 +629,25 @@ func SetObjectDefaults_StatefulSet(in *v1beta1.StatefulSet) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
for i := range in.Spec.VolumeClaimTemplates {
|
||||
a := &in.Spec.VolumeClaimTemplates[i]
|
||||
v1.SetDefaults_PersistentVolumeClaim(a)
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Spec.Resources.Requests)
|
||||
v1.SetDefaults_ResourceList(&a.Status.Capacity)
|
||||
v1.SetDefaults_ResourceList(&a.Status.AllocatedResources)
|
||||
corev1.SetDefaults_PersistentVolumeClaim(a)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Status.Capacity)
|
||||
corev1.SetDefaults_ResourceList(&a.Status.AllocatedResources)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
567
pkg/apis/apps/v1beta2/zz_generated.defaults.go
generated
567
pkg/apis/apps/v1beta2/zz_generated.defaults.go
generated
File diff suppressed because it is too large
Load Diff
279
pkg/apis/batch/v1/zz_generated.defaults.go
generated
279
pkg/apis/batch/v1/zz_generated.defaults.go
generated
@@ -23,8 +23,9 @@ package v1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/batch/v1"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
apiscorev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -40,68 +41,98 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
|
||||
|
||||
func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
SetDefaults_CronJob(in)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.JobTemplate.Spec.Template.Spec)
|
||||
apiscorev1.SetDefaults_PodSpec(&in.Spec.JobTemplate.Spec.Template.Spec)
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.Volumes[i]
|
||||
corev1.SetDefaults_Volume(a)
|
||||
apiscorev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
apiscorev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
apiscorev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
corev1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
corev1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
apiscorev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
apiscorev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
corev1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskCachingMode(corev1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskKind(corev1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
apiscorev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
apiscorev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
corev1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
apiscorev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.InitContainers[i]
|
||||
corev1.SetDefaults_Container(a)
|
||||
apiscorev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -112,16 +143,16 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -131,9 +162,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -143,9 +174,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -157,19 +188,19 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.Containers[i]
|
||||
corev1.SetDefaults_Container(a)
|
||||
apiscorev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -180,16 +211,16 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -199,9 +230,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -211,9 +242,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -225,19 +256,19 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.EphemeralContainers[i]
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
apiscorev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -248,16 +279,16 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -267,9 +298,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -279,9 +310,9 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -293,17 +324,17 @@ func SetObjectDefaults_CronJob(in *v1.CronJob) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.JobTemplate.Spec.Template.Spec.Overhead)
|
||||
apiscorev1.SetDefaults_ResourceList(&in.Spec.JobTemplate.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_CronJobList(in *v1.CronJobList) {
|
||||
@@ -315,68 +346,98 @@ func SetObjectDefaults_CronJobList(in *v1.CronJobList) {
|
||||
|
||||
func SetObjectDefaults_Job(in *v1.Job) {
|
||||
SetDefaults_Job(in)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
apiscorev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
corev1.SetDefaults_Volume(a)
|
||||
apiscorev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
apiscorev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
apiscorev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
corev1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
corev1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
apiscorev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
apiscorev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
corev1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskCachingMode(corev1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskKind(corev1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
apiscorev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
apiscorev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
corev1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
apiscorev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
corev1.SetDefaults_Container(a)
|
||||
apiscorev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -387,16 +448,16 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -406,9 +467,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -418,9 +479,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -432,19 +493,19 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
corev1.SetDefaults_Container(a)
|
||||
apiscorev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -455,16 +516,16 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -474,9 +535,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -486,9 +547,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -500,19 +561,19 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
apiscorev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -523,16 +584,16 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
apiscorev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
apiscorev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -542,9 +603,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -554,9 +615,9 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
apiscorev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -568,17 +629,17 @@ func SetObjectDefaults_Job(in *v1.Job) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
apiscorev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
apiscorev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_JobList(in *v1.JobList) {
|
||||
|
||||
141
pkg/apis/batch/v1beta1/zz_generated.defaults.go
generated
141
pkg/apis/batch/v1beta1/zz_generated.defaults.go
generated
@@ -23,8 +23,9 @@ package v1beta1
|
||||
|
||||
import (
|
||||
v1beta1 "k8s.io/api/batch/v1beta1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
v1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -38,68 +39,98 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
|
||||
|
||||
func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
SetDefaults_CronJob(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.JobTemplate.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.JobTemplate.Spec.Template.Spec)
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -110,16 +141,16 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -129,9 +160,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -141,9 +172,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -155,19 +186,19 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -178,16 +209,16 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -197,9 +228,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -209,9 +240,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -223,19 +254,19 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.JobTemplate.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.JobTemplate.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -246,16 +277,16 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -265,9 +296,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -277,9 +308,9 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -291,17 +322,17 @@ func SetObjectDefaults_CronJob(in *v1beta1.CronJob) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.JobTemplate.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.JobTemplate.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_CronJobList(in *v1beta1.CronJobList) {
|
||||
|
||||
@@ -311,34 +311,6 @@ func SetDefaults_PersistentVolumeClaimSpec(obj *v1.PersistentVolumeClaimSpec) {
|
||||
*obj.VolumeMode = v1.PersistentVolumeFilesystem
|
||||
}
|
||||
}
|
||||
func SetDefaults_ISCSIVolumeSource(obj *v1.ISCSIVolumeSource) {
|
||||
if obj.ISCSIInterface == "" {
|
||||
obj.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
func SetDefaults_ISCSIPersistentVolumeSource(obj *v1.ISCSIPersistentVolumeSource) {
|
||||
if obj.ISCSIInterface == "" {
|
||||
obj.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
func SetDefaults_AzureDiskVolumeSource(obj *v1.AzureDiskVolumeSource) {
|
||||
if obj.CachingMode == nil {
|
||||
obj.CachingMode = new(v1.AzureDataDiskCachingMode)
|
||||
*obj.CachingMode = v1.AzureDataDiskCachingReadWrite
|
||||
}
|
||||
if obj.Kind == nil {
|
||||
obj.Kind = new(v1.AzureDataDiskKind)
|
||||
*obj.Kind = v1.AzureSharedBlobDisk
|
||||
}
|
||||
if obj.FSType == nil {
|
||||
obj.FSType = new(string)
|
||||
*obj.FSType = "ext4"
|
||||
}
|
||||
if obj.ReadOnly == nil {
|
||||
obj.ReadOnly = new(bool)
|
||||
*obj.ReadOnly = false
|
||||
}
|
||||
}
|
||||
func SetDefaults_Endpoints(obj *v1.Endpoints) {
|
||||
for i := range obj.Subsets {
|
||||
ss := &obj.Subsets[i]
|
||||
@@ -442,48 +414,6 @@ func defaultHostNetworkPorts(containers *[]v1.Container) {
|
||||
}
|
||||
}
|
||||
|
||||
func SetDefaults_RBDVolumeSource(obj *v1.RBDVolumeSource) {
|
||||
if obj.RBDPool == "" {
|
||||
obj.RBDPool = "rbd"
|
||||
}
|
||||
if obj.RadosUser == "" {
|
||||
obj.RadosUser = "admin"
|
||||
}
|
||||
if obj.Keyring == "" {
|
||||
obj.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
|
||||
func SetDefaults_RBDPersistentVolumeSource(obj *v1.RBDPersistentVolumeSource) {
|
||||
if obj.RBDPool == "" {
|
||||
obj.RBDPool = "rbd"
|
||||
}
|
||||
if obj.RadosUser == "" {
|
||||
obj.RadosUser = "admin"
|
||||
}
|
||||
if obj.Keyring == "" {
|
||||
obj.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
|
||||
func SetDefaults_ScaleIOVolumeSource(obj *v1.ScaleIOVolumeSource) {
|
||||
if obj.StorageMode == "" {
|
||||
obj.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if obj.FSType == "" {
|
||||
obj.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
|
||||
func SetDefaults_ScaleIOPersistentVolumeSource(obj *v1.ScaleIOPersistentVolumeSource) {
|
||||
if obj.StorageMode == "" {
|
||||
obj.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if obj.FSType == "" {
|
||||
obj.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
|
||||
func SetDefaults_HostPathVolumeSource(obj *v1.HostPathVolumeSource) {
|
||||
typeVol := v1.HostPathUnset
|
||||
if obj.Type == nil {
|
||||
|
||||
152
pkg/apis/core/v1/zz_generated.defaults.go
generated
152
pkg/apis/core/v1/zz_generated.defaults.go
generated
@@ -137,16 +137,46 @@ func SetObjectDefaults_PersistentVolume(in *v1.PersistentVolume) {
|
||||
SetDefaults_HostPathVolumeSource(in.Spec.PersistentVolumeSource.HostPath)
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.RBD != nil {
|
||||
SetDefaults_RBDPersistentVolumeSource(in.Spec.PersistentVolumeSource.RBD)
|
||||
if in.Spec.PersistentVolumeSource.RBD.RBDPool == "" {
|
||||
in.Spec.PersistentVolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.RBD.RadosUser == "" {
|
||||
in.Spec.PersistentVolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.RBD.Keyring == "" {
|
||||
in.Spec.PersistentVolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.ISCSI != nil {
|
||||
SetDefaults_ISCSIPersistentVolumeSource(in.Spec.PersistentVolumeSource.ISCSI)
|
||||
if in.Spec.PersistentVolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
in.Spec.PersistentVolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.AzureDisk != nil {
|
||||
SetDefaults_AzureDiskVolumeSource(in.Spec.PersistentVolumeSource.AzureDisk)
|
||||
if in.Spec.PersistentVolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
in.Spec.PersistentVolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
in.Spec.PersistentVolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
in.Spec.PersistentVolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
in.Spec.PersistentVolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.ScaleIO != nil {
|
||||
SetDefaults_ScaleIOPersistentVolumeSource(in.Spec.PersistentVolumeSource.ScaleIO)
|
||||
if in.Spec.PersistentVolumeSource.ScaleIO.StorageMode == "" {
|
||||
in.Spec.PersistentVolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if in.Spec.PersistentVolumeSource.ScaleIO.FSType == "" {
|
||||
in.Spec.PersistentVolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -186,10 +216,20 @@ func SetObjectDefaults_Pod(in *v1.Pod) {
|
||||
SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
@@ -204,7 +244,22 @@ func SetObjectDefaults_Pod(in *v1.Pod) {
|
||||
SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
@@ -224,7 +279,12 @@ func SetObjectDefaults_Pod(in *v1.Pod) {
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
@@ -511,10 +571,20 @@ func SetObjectDefaults_PodTemplate(in *v1.PodTemplate) {
|
||||
SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
@@ -529,7 +599,22 @@ func SetObjectDefaults_PodTemplate(in *v1.PodTemplate) {
|
||||
SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
@@ -549,7 +634,12 @@ func SetObjectDefaults_PodTemplate(in *v1.PodTemplate) {
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
@@ -787,10 +877,20 @@ func SetObjectDefaults_ReplicationController(in *v1.ReplicationController) {
|
||||
SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
@@ -805,7 +905,22 @@ func SetObjectDefaults_ReplicationController(in *v1.ReplicationController) {
|
||||
SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
@@ -825,7 +940,12 @@ func SetObjectDefaults_ReplicationController(in *v1.ReplicationController) {
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
|
||||
417
pkg/apis/extensions/v1beta1/zz_generated.defaults.go
generated
417
pkg/apis/extensions/v1beta1/zz_generated.defaults.go
generated
@@ -22,9 +22,10 @@ limitations under the License.
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/core/v1"
|
||||
v1beta1 "k8s.io/api/extensions/v1beta1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
v1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -46,68 +47,98 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
|
||||
|
||||
func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
SetDefaults_DaemonSet(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -118,16 +149,16 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -137,9 +168,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -149,9 +180,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -163,19 +194,19 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -186,16 +217,16 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -205,9 +236,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -217,9 +248,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -231,19 +262,19 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -254,16 +285,16 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -273,9 +304,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -285,9 +316,9 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -299,17 +330,17 @@ func SetObjectDefaults_DaemonSet(in *v1beta1.DaemonSet) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_DaemonSetList(in *v1beta1.DaemonSetList) {
|
||||
@@ -321,68 +352,98 @@ func SetObjectDefaults_DaemonSetList(in *v1beta1.DaemonSetList) {
|
||||
|
||||
func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
SetDefaults_Deployment(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -393,16 +454,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -412,9 +473,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -424,9 +485,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -438,19 +499,19 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -461,16 +522,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -480,9 +541,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -492,9 +553,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -506,19 +567,19 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -529,16 +590,16 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -548,9 +609,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -560,9 +621,9 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -574,17 +635,17 @@ func SetObjectDefaults_Deployment(in *v1beta1.Deployment) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_DeploymentList(in *v1beta1.DeploymentList) {
|
||||
@@ -626,68 +687,98 @@ func SetObjectDefaults_NetworkPolicyList(in *v1beta1.NetworkPolicyList) {
|
||||
|
||||
func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
SetDefaults_ReplicaSet(in)
|
||||
v1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
corev1.SetDefaults_PodSpec(&in.Spec.Template.Spec)
|
||||
for i := range in.Spec.Template.Spec.Volumes {
|
||||
a := &in.Spec.Template.Spec.Volumes[i]
|
||||
v1.SetDefaults_Volume(a)
|
||||
corev1.SetDefaults_Volume(a)
|
||||
if a.VolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(a.VolumeSource.HostPath)
|
||||
}
|
||||
if a.VolumeSource.Secret != nil {
|
||||
v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
corev1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret)
|
||||
}
|
||||
if a.VolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI)
|
||||
if a.VolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
a.VolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD)
|
||||
if a.VolumeSource.RBD.RBDPool == "" {
|
||||
a.VolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if a.VolumeSource.RBD.RadosUser == "" {
|
||||
a.VolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if a.VolumeSource.RBD.Keyring == "" {
|
||||
a.VolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.DownwardAPI != nil {
|
||||
v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
corev1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI)
|
||||
for j := range a.VolumeSource.DownwardAPI.Items {
|
||||
b := &a.VolumeSource.DownwardAPI.Items[j]
|
||||
if b.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ConfigMap != nil {
|
||||
v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
corev1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap)
|
||||
}
|
||||
if a.VolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk)
|
||||
if a.VolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
a.VolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
a.VolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
a.VolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if a.VolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
a.VolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Projected != nil {
|
||||
v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
corev1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected)
|
||||
for j := range a.VolumeSource.Projected.Sources {
|
||||
b := &a.VolumeSource.Projected.Sources[j]
|
||||
if b.DownwardAPI != nil {
|
||||
for k := range b.DownwardAPI.Items {
|
||||
c := &b.DownwardAPI.Items[k]
|
||||
if c.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(c.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
if b.ServiceAccountToken != nil {
|
||||
v1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
corev1.SetDefaults_ServiceAccountTokenProjection(b.ServiceAccountToken)
|
||||
}
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO)
|
||||
if a.VolumeSource.ScaleIO.StorageMode == "" {
|
||||
a.VolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if a.VolumeSource.ScaleIO.FSType == "" {
|
||||
a.VolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
if a.VolumeSource.Ephemeral != nil {
|
||||
if a.VolumeSource.Ephemeral.VolumeClaimTemplate != nil {
|
||||
v1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
corev1.SetDefaults_PersistentVolumeClaimSpec(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.VolumeSource.Ephemeral.VolumeClaimTemplate.Spec.Resources.Requests)
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.InitContainers {
|
||||
a := &in.Spec.Template.Spec.InitContainers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -698,16 +789,16 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -717,9 +808,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -729,9 +820,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -743,19 +834,19 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.Containers {
|
||||
a := &in.Spec.Template.Spec.Containers[i]
|
||||
v1.SetDefaults_Container(a)
|
||||
corev1.SetDefaults_Container(a)
|
||||
for j := range a.Ports {
|
||||
b := &a.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -766,16 +857,16 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
b := &a.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.Resources.Requests)
|
||||
if a.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.LivenessProbe)
|
||||
if a.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -785,9 +876,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.ReadinessProbe)
|
||||
if a.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -797,9 +888,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.StartupProbe)
|
||||
if a.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -811,19 +902,19 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
if a.Lifecycle != nil {
|
||||
if a.Lifecycle.PostStart != nil {
|
||||
if a.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.Lifecycle.PreStop != nil {
|
||||
if a.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
for i := range in.Spec.Template.Spec.EphemeralContainers {
|
||||
a := &in.Spec.Template.Spec.EphemeralContainers[i]
|
||||
v1.SetDefaults_EphemeralContainer(a)
|
||||
corev1.SetDefaults_EphemeralContainer(a)
|
||||
for j := range a.EphemeralContainerCommon.Ports {
|
||||
b := &a.EphemeralContainerCommon.Ports[j]
|
||||
if b.Protocol == "" {
|
||||
@@ -834,16 +925,16 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
b := &a.EphemeralContainerCommon.Env[j]
|
||||
if b.ValueFrom != nil {
|
||||
if b.ValueFrom.FieldRef != nil {
|
||||
v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
corev1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef)
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
v1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Limits)
|
||||
corev1.SetDefaults_ResourceList(&a.EphemeralContainerCommon.Resources.Requests)
|
||||
if a.EphemeralContainerCommon.LivenessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.LivenessProbe)
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.LivenessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -853,9 +944,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.ReadinessProbe)
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.ReadinessProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -865,9 +956,9 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe != nil {
|
||||
v1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
corev1.SetDefaults_Probe(a.EphemeralContainerCommon.StartupProbe)
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.StartupProbe.ProbeHandler.HTTPGet)
|
||||
}
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC != nil {
|
||||
if a.EphemeralContainerCommon.StartupProbe.ProbeHandler.GRPC.Service == nil {
|
||||
@@ -879,17 +970,17 @@ func SetObjectDefaults_ReplicaSet(in *v1beta1.ReplicaSet) {
|
||||
if a.EphemeralContainerCommon.Lifecycle != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PostStart.HTTPGet)
|
||||
}
|
||||
}
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop != nil {
|
||||
if a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet != nil {
|
||||
v1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
corev1.SetDefaults_HTTPGetAction(a.EphemeralContainerCommon.Lifecycle.PreStop.HTTPGet)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Template.Spec.Overhead)
|
||||
}
|
||||
|
||||
func SetObjectDefaults_ReplicaSetList(in *v1beta1.ReplicaSetList) {
|
||||
|
||||
45
pkg/apis/storage/v1/zz_generated.defaults.go
generated
45
pkg/apis/storage/v1/zz_generated.defaults.go
generated
@@ -22,9 +22,10 @@ limitations under the License.
|
||||
package v1
|
||||
|
||||
import (
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
v1 "k8s.io/api/storage/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
apiscorev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -64,21 +65,51 @@ func SetObjectDefaults_StorageClassList(in *v1.StorageClassList) {
|
||||
|
||||
func SetObjectDefaults_VolumeAttachment(in *v1.VolumeAttachment) {
|
||||
if in.Spec.Source.InlineVolumeSpec != nil {
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
apiscorev1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath != nil {
|
||||
corev1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
apiscorev1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD != nil {
|
||||
corev1.SetDefaults_RBDPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI != nil {
|
||||
corev1.SetDefaults_ISCSIPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk != nil {
|
||||
corev1.SetDefaults_AzureDiskVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskCachingMode(corev1.AzureDataDiskCachingReadWrite)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := corev1.AzureDataDiskKind(corev1.AzureSharedBlobDisk)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO != nil {
|
||||
corev1.SetDefaults_ScaleIOPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
45
pkg/apis/storage/v1alpha1/zz_generated.defaults.go
generated
45
pkg/apis/storage/v1alpha1/zz_generated.defaults.go
generated
@@ -22,9 +22,10 @@ limitations under the License.
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/core/v1"
|
||||
v1alpha1 "k8s.io/api/storage/v1alpha1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
v1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -38,21 +39,51 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
|
||||
|
||||
func SetObjectDefaults_VolumeAttachment(in *v1alpha1.VolumeAttachment) {
|
||||
if in.Spec.Source.InlineVolumeSpec != nil {
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
45
pkg/apis/storage/v1beta1/zz_generated.defaults.go
generated
45
pkg/apis/storage/v1beta1/zz_generated.defaults.go
generated
@@ -22,9 +22,10 @@ limitations under the License.
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/core/v1"
|
||||
v1beta1 "k8s.io/api/storage/v1beta1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
v1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
corev1 "k8s.io/kubernetes/pkg/apis/core/v1"
|
||||
)
|
||||
|
||||
// RegisterDefaults adds defaulters functions to the given scheme.
|
||||
@@ -64,21 +65,51 @@ func SetObjectDefaults_StorageClassList(in *v1beta1.StorageClassList) {
|
||||
|
||||
func SetObjectDefaults_VolumeAttachment(in *v1beta1.VolumeAttachment) {
|
||||
if in.Spec.Source.InlineVolumeSpec != nil {
|
||||
v1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
corev1.SetDefaults_ResourceList(&in.Spec.Source.InlineVolumeSpec.Capacity)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath != nil {
|
||||
v1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
corev1.SetDefaults_HostPathVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.HostPath)
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD != nil {
|
||||
v1.SetDefaults_RBDPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RBDPool = "rbd"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.RadosUser = "admin"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.RBD.Keyring = "/etc/ceph/keyring"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI != nil {
|
||||
v1.SetDefaults_ISCSIPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ISCSI.ISCSIInterface = "default"
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk != nil {
|
||||
v1.SetDefaults_AzureDiskVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode == nil {
|
||||
ptrVar1 := v1.AzureDataDiskCachingMode(v1.AzureDataDiskCachingReadWrite)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.CachingMode = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType == nil {
|
||||
var ptrVar1 string = "ext4"
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.FSType = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly == nil {
|
||||
var ptrVar1 bool = false
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.ReadOnly = &ptrVar1
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind == nil {
|
||||
ptrVar1 := v1.AzureDataDiskKind(v1.AzureSharedBlobDisk)
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.AzureDisk.Kind = &ptrVar1
|
||||
}
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO != nil {
|
||||
v1.SetDefaults_ScaleIOPersistentVolumeSource(in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO)
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.StorageMode = "ThinProvisioned"
|
||||
}
|
||||
if in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType == "" {
|
||||
in.Spec.Source.InlineVolumeSpec.PersistentVolumeSource.ScaleIO.FSType = "xfs"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
35
pkg/generated/openapi/zz_generated.openapi.go
generated
35
pkg/generated/openapi/zz_generated.openapi.go
generated
@@ -22,7 +22,8 @@ limitations under the License.
|
||||
package openapi
|
||||
|
||||
import (
|
||||
v1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
apiextensionsv1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
|
||||
v1beta1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1"
|
||||
resource "k8s.io/apimachinery/pkg/api/resource"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
@@ -19109,6 +19110,7 @@ func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback
|
||||
"cachingMode": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "cachingMode is the Host Caching mode: None, Read Only, Read Write.\n\nPossible enum values:\n - `\"None\"`\n - `\"ReadOnly\"`\n - `\"ReadWrite\"`",
|
||||
Default: v1.AzureDataDiskCachingReadWrite,
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
Enum: []interface{}{"None", "ReadOnly", "ReadWrite"},
|
||||
@@ -19117,6 +19119,7 @@ func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback
|
||||
"fsType": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.",
|
||||
Default: "ext4",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -19124,6 +19127,7 @@ func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback
|
||||
"readOnly": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.",
|
||||
Default: false,
|
||||
Type: []string{"boolean"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -19131,6 +19135,7 @@ func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback
|
||||
"kind": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared\n\nPossible enum values:\n - `\"Dedicated\"`\n - `\"Managed\"`\n - `\"Shared\"`",
|
||||
Default: v1.AzureSharedBlobDisk,
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
Enum: []interface{}{"Dedicated", "Managed", "Shared"},
|
||||
@@ -23113,6 +23118,7 @@ func schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref common.ReferenceCa
|
||||
"iscsiInterface": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
Default: "default",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -23221,6 +23227,7 @@ func schema_k8sio_api_core_v1_ISCSIVolumeSource(ref common.ReferenceCallback) co
|
||||
"iscsiInterface": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).",
|
||||
Default: "default",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28552,6 +28559,7 @@ func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCall
|
||||
"pool": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "rbd",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28559,6 +28567,7 @@ func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCall
|
||||
"user": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "admin",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28566,6 +28575,7 @@ func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCall
|
||||
"keyring": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "/etc/ceph/keyring",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28637,6 +28647,7 @@ func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) comm
|
||||
"pool": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "rbd",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28644,6 +28655,7 @@ func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) comm
|
||||
"user": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "admin",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -28651,6 +28663,7 @@ func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) comm
|
||||
"keyring": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it",
|
||||
Default: "/etc/ceph/keyring",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -29437,6 +29450,7 @@ func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.Reference
|
||||
"storageMode": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
Default: "ThinProvisioned",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -29451,6 +29465,7 @@ func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.Reference
|
||||
"fsType": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\"",
|
||||
Default: "xfs",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -29524,6 +29539,7 @@ func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback)
|
||||
"storageMode": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.",
|
||||
Default: "ThinProvisioned",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -29538,6 +29554,7 @@ func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback)
|
||||
"fsType": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".",
|
||||
Default: "xfs",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
@@ -50745,8 +50762,8 @@ func schema_pkg_apis_apiextensions_v1_JSON(ref common.ReferenceCallback) common.
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "JSON represents any valid JSON value. These types are supported: bool, int64, float64, string, []interface{}, map[string]interface{} and nil.",
|
||||
Type: v1.JSON{}.OpenAPISchemaType(),
|
||||
Format: v1.JSON{}.OpenAPISchemaFormat(),
|
||||
Type: apiextensionsv1.JSON{}.OpenAPISchemaType(),
|
||||
Format: apiextensionsv1.JSON{}.OpenAPISchemaFormat(),
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -51159,8 +51176,8 @@ func schema_pkg_apis_apiextensions_v1_JSONSchemaPropsOrArray(ref common.Referenc
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "JSONSchemaPropsOrArray represents a value that can either be a JSONSchemaProps or an array of JSONSchemaProps. Mainly here for serialization purposes.",
|
||||
Type: v1.JSONSchemaPropsOrArray{}.OpenAPISchemaType(),
|
||||
Format: v1.JSONSchemaPropsOrArray{}.OpenAPISchemaFormat(),
|
||||
Type: apiextensionsv1.JSONSchemaPropsOrArray{}.OpenAPISchemaType(),
|
||||
Format: apiextensionsv1.JSONSchemaPropsOrArray{}.OpenAPISchemaFormat(),
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -51171,8 +51188,8 @@ func schema_pkg_apis_apiextensions_v1_JSONSchemaPropsOrBool(ref common.Reference
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "JSONSchemaPropsOrBool represents JSONSchemaProps or a boolean value. Defaults to true for the boolean property.",
|
||||
Type: v1.JSONSchemaPropsOrBool{}.OpenAPISchemaType(),
|
||||
Format: v1.JSONSchemaPropsOrBool{}.OpenAPISchemaFormat(),
|
||||
Type: apiextensionsv1.JSONSchemaPropsOrBool{}.OpenAPISchemaType(),
|
||||
Format: apiextensionsv1.JSONSchemaPropsOrBool{}.OpenAPISchemaFormat(),
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -51183,8 +51200,8 @@ func schema_pkg_apis_apiextensions_v1_JSONSchemaPropsOrStringArray(ref common.Re
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "JSONSchemaPropsOrStringArray represents a JSONSchemaProps or a string array.",
|
||||
Type: v1.JSONSchemaPropsOrStringArray{}.OpenAPISchemaType(),
|
||||
Format: v1.JSONSchemaPropsOrStringArray{}.OpenAPISchemaFormat(),
|
||||
Type: apiextensionsv1.JSONSchemaPropsOrStringArray{}.OpenAPISchemaType(),
|
||||
Format: apiextensionsv1.JSONSchemaPropsOrStringArray{}.OpenAPISchemaFormat(),
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
@@ -126,20 +126,24 @@ message AzureDiskVolumeSource {
|
||||
|
||||
// cachingMode is the Host Caching mode: None, Read Only, Read Write.
|
||||
// +optional
|
||||
// +default=ref(AzureDataDiskCachingReadWrite)
|
||||
optional string cachingMode = 3;
|
||||
|
||||
// fsType is Filesystem type to mount.
|
||||
// Must be a filesystem type supported by the host operating system.
|
||||
// Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
|
||||
// +optional
|
||||
// +default="ext4"
|
||||
optional string fsType = 4;
|
||||
|
||||
// readOnly Defaults to false (read/write). ReadOnly here will force
|
||||
// the ReadOnly setting in VolumeMounts.
|
||||
// +optional
|
||||
// +default=false
|
||||
optional bool readOnly = 5;
|
||||
|
||||
// kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared
|
||||
// +default=ref(AzureSharedBlobDisk)
|
||||
optional string kind = 6;
|
||||
}
|
||||
|
||||
@@ -2045,6 +2049,7 @@ message ISCSIPersistentVolumeSource {
|
||||
// iscsiInterface is the interface Name that uses an iSCSI transport.
|
||||
// Defaults to 'default' (tcp).
|
||||
// +optional
|
||||
// +default="default"
|
||||
optional string iscsiInterface = 4;
|
||||
|
||||
// fsType is the filesystem type of the volume that you want to mount.
|
||||
@@ -2102,6 +2107,7 @@ message ISCSIVolumeSource {
|
||||
// iscsiInterface is the interface Name that uses an iSCSI transport.
|
||||
// Defaults to 'default' (tcp).
|
||||
// +optional
|
||||
// +default="default"
|
||||
optional string iscsiInterface = 4;
|
||||
|
||||
// fsType is the filesystem type of the volume that you want to mount.
|
||||
@@ -4729,18 +4735,21 @@ message RBDPersistentVolumeSource {
|
||||
// Default is rbd.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="rbd"
|
||||
optional string pool = 4;
|
||||
|
||||
// user is the rados user name.
|
||||
// Default is admin.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="admin"
|
||||
optional string user = 5;
|
||||
|
||||
// keyring is the path to key ring for RBDUser.
|
||||
// Default is /etc/ceph/keyring.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="/etc/ceph/keyring"
|
||||
optional string keyring = 6;
|
||||
|
||||
// secretRef is name of the authentication secret for RBDUser. If provided
|
||||
@@ -4781,18 +4790,21 @@ message RBDVolumeSource {
|
||||
// Default is rbd.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="rbd"
|
||||
optional string pool = 4;
|
||||
|
||||
// user is the rados user name.
|
||||
// Default is admin.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="admin"
|
||||
optional string user = 5;
|
||||
|
||||
// keyring is the path to key ring for RBDUser.
|
||||
// Default is /etc/ceph/keyring.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="/etc/ceph/keyring"
|
||||
optional string keyring = 6;
|
||||
|
||||
// secretRef is name of the authentication secret for RBDUser. If provided
|
||||
@@ -5102,6 +5114,7 @@ message ScaleIOPersistentVolumeSource {
|
||||
// storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
|
||||
// Default is ThinProvisioned.
|
||||
// +optional
|
||||
// +default="ThinProvisioned"
|
||||
optional string storageMode = 7;
|
||||
|
||||
// volumeName is the name of a volume already created in the ScaleIO system
|
||||
@@ -5113,6 +5126,7 @@ message ScaleIOPersistentVolumeSource {
|
||||
// Ex. "ext4", "xfs", "ntfs".
|
||||
// Default is "xfs"
|
||||
// +optional
|
||||
// +default="xfs"
|
||||
optional string fsType = 9;
|
||||
|
||||
// readOnly defaults to false (read/write). ReadOnly here will force
|
||||
@@ -5148,6 +5162,7 @@ message ScaleIOVolumeSource {
|
||||
// storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
|
||||
// Default is ThinProvisioned.
|
||||
// +optional
|
||||
// +default="ThinProvisioned"
|
||||
optional string storageMode = 7;
|
||||
|
||||
// volumeName is the name of a volume already created in the ScaleIO system
|
||||
@@ -5159,6 +5174,7 @@ message ScaleIOVolumeSource {
|
||||
// Ex. "ext4", "xfs", "ntfs".
|
||||
// Default is "xfs".
|
||||
// +optional
|
||||
// +default="xfs"
|
||||
optional string fsType = 9;
|
||||
|
||||
// readOnly Defaults to false (read/write). ReadOnly here will force
|
||||
|
||||
@@ -947,16 +947,19 @@ type RBDVolumeSource struct {
|
||||
// Default is rbd.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="rbd"
|
||||
RBDPool string `json:"pool,omitempty" protobuf:"bytes,4,opt,name=pool"`
|
||||
// user is the rados user name.
|
||||
// Default is admin.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="admin"
|
||||
RadosUser string `json:"user,omitempty" protobuf:"bytes,5,opt,name=user"`
|
||||
// keyring is the path to key ring for RBDUser.
|
||||
// Default is /etc/ceph/keyring.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="/etc/ceph/keyring"
|
||||
Keyring string `json:"keyring,omitempty" protobuf:"bytes,6,opt,name=keyring"`
|
||||
// secretRef is name of the authentication secret for RBDUser. If provided
|
||||
// overrides keyring.
|
||||
@@ -992,16 +995,19 @@ type RBDPersistentVolumeSource struct {
|
||||
// Default is rbd.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="rbd"
|
||||
RBDPool string `json:"pool,omitempty" protobuf:"bytes,4,opt,name=pool"`
|
||||
// user is the rados user name.
|
||||
// Default is admin.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="admin"
|
||||
RadosUser string `json:"user,omitempty" protobuf:"bytes,5,opt,name=user"`
|
||||
// keyring is the path to key ring for RBDUser.
|
||||
// Default is /etc/ceph/keyring.
|
||||
// More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it
|
||||
// +optional
|
||||
// +default="/etc/ceph/keyring"
|
||||
Keyring string `json:"keyring,omitempty" protobuf:"bytes,6,opt,name=keyring"`
|
||||
// secretRef is name of the authentication secret for RBDUser. If provided
|
||||
// overrides keyring.
|
||||
@@ -1430,6 +1436,7 @@ type ISCSIVolumeSource struct {
|
||||
// iscsiInterface is the interface Name that uses an iSCSI transport.
|
||||
// Defaults to 'default' (tcp).
|
||||
// +optional
|
||||
// +default="default"
|
||||
ISCSIInterface string `json:"iscsiInterface,omitempty" protobuf:"bytes,4,opt,name=iscsiInterface"`
|
||||
// fsType is the filesystem type of the volume that you want to mount.
|
||||
// Tip: Ensure that the filesystem type is supported by the host operating system.
|
||||
@@ -1477,6 +1484,7 @@ type ISCSIPersistentVolumeSource struct {
|
||||
// iscsiInterface is the interface Name that uses an iSCSI transport.
|
||||
// Defaults to 'default' (tcp).
|
||||
// +optional
|
||||
// +default="default"
|
||||
ISCSIInterface string `json:"iscsiInterface,omitempty" protobuf:"bytes,4,opt,name=iscsiInterface"`
|
||||
// fsType is the filesystem type of the volume that you want to mount.
|
||||
// Tip: Ensure that the filesystem type is supported by the host operating system.
|
||||
@@ -1617,17 +1625,21 @@ type AzureDiskVolumeSource struct {
|
||||
DataDiskURI string `json:"diskURI" protobuf:"bytes,2,opt,name=diskURI"`
|
||||
// cachingMode is the Host Caching mode: None, Read Only, Read Write.
|
||||
// +optional
|
||||
// +default=ref(AzureDataDiskCachingReadWrite)
|
||||
CachingMode *AzureDataDiskCachingMode `json:"cachingMode,omitempty" protobuf:"bytes,3,opt,name=cachingMode,casttype=AzureDataDiskCachingMode"`
|
||||
// fsType is Filesystem type to mount.
|
||||
// Must be a filesystem type supported by the host operating system.
|
||||
// Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified.
|
||||
// +optional
|
||||
// +default="ext4"
|
||||
FSType *string `json:"fsType,omitempty" protobuf:"bytes,4,opt,name=fsType"`
|
||||
// readOnly Defaults to false (read/write). ReadOnly here will force
|
||||
// the ReadOnly setting in VolumeMounts.
|
||||
// +optional
|
||||
// +default=false
|
||||
ReadOnly *bool `json:"readOnly,omitempty" protobuf:"varint,5,opt,name=readOnly"`
|
||||
// kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared
|
||||
// +default=ref(AzureSharedBlobDisk)
|
||||
Kind *AzureDataDiskKind `json:"kind,omitempty" protobuf:"bytes,6,opt,name=kind,casttype=AzureDataDiskKind"`
|
||||
}
|
||||
|
||||
@@ -1666,6 +1678,7 @@ type ScaleIOVolumeSource struct {
|
||||
// storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
|
||||
// Default is ThinProvisioned.
|
||||
// +optional
|
||||
// +default="ThinProvisioned"
|
||||
StorageMode string `json:"storageMode,omitempty" protobuf:"bytes,7,opt,name=storageMode"`
|
||||
// volumeName is the name of a volume already created in the ScaleIO system
|
||||
// that is associated with this volume source.
|
||||
@@ -1675,6 +1688,7 @@ type ScaleIOVolumeSource struct {
|
||||
// Ex. "ext4", "xfs", "ntfs".
|
||||
// Default is "xfs".
|
||||
// +optional
|
||||
// +default="xfs"
|
||||
FSType string `json:"fsType,omitempty" protobuf:"bytes,9,opt,name=fsType"`
|
||||
// readOnly Defaults to false (read/write). ReadOnly here will force
|
||||
// the ReadOnly setting in VolumeMounts.
|
||||
@@ -1703,6 +1717,7 @@ type ScaleIOPersistentVolumeSource struct {
|
||||
// storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned.
|
||||
// Default is ThinProvisioned.
|
||||
// +optional
|
||||
// +default="ThinProvisioned"
|
||||
StorageMode string `json:"storageMode,omitempty" protobuf:"bytes,7,opt,name=storageMode"`
|
||||
// volumeName is the name of a volume already created in the ScaleIO system
|
||||
// that is associated with this volume source.
|
||||
@@ -1712,6 +1727,7 @@ type ScaleIOPersistentVolumeSource struct {
|
||||
// Ex. "ext4", "xfs", "ntfs".
|
||||
// Default is "xfs"
|
||||
// +optional
|
||||
// +default="xfs"
|
||||
FSType string `json:"fsType,omitempty" protobuf:"bytes,9,opt,name=fsType"`
|
||||
// readOnly defaults to false (read/write). ReadOnly here will force
|
||||
// the ReadOnly setting in VolumeMounts.
|
||||
|
||||
@@ -4454,6 +4454,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: cachingMode
|
||||
type:
|
||||
scalar: string
|
||||
default: ReadWrite
|
||||
- name: diskName
|
||||
type:
|
||||
scalar: string
|
||||
@@ -4465,12 +4466,15 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: fsType
|
||||
type:
|
||||
scalar: string
|
||||
default: ext4
|
||||
- name: kind
|
||||
type:
|
||||
scalar: string
|
||||
default: Shared
|
||||
- name: readOnly
|
||||
type:
|
||||
scalar: boolean
|
||||
default: false
|
||||
- name: io.k8s.api.core.v1.AzureFilePersistentVolumeSource
|
||||
map:
|
||||
fields:
|
||||
@@ -5702,6 +5706,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: iscsiInterface
|
||||
type:
|
||||
scalar: string
|
||||
default: default
|
||||
- name: lun
|
||||
type:
|
||||
scalar: numeric
|
||||
@@ -5744,6 +5749,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: iscsiInterface
|
||||
type:
|
||||
scalar: string
|
||||
default: default
|
||||
- name: lun
|
||||
type:
|
||||
scalar: numeric
|
||||
@@ -7262,6 +7268,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: keyring
|
||||
type:
|
||||
scalar: string
|
||||
default: /etc/ceph/keyring
|
||||
- name: monitors
|
||||
type:
|
||||
list:
|
||||
@@ -7271,6 +7278,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: pool
|
||||
type:
|
||||
scalar: string
|
||||
default: rbd
|
||||
- name: readOnly
|
||||
type:
|
||||
scalar: boolean
|
||||
@@ -7280,6 +7288,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: user
|
||||
type:
|
||||
scalar: string
|
||||
default: admin
|
||||
- name: io.k8s.api.core.v1.RBDVolumeSource
|
||||
map:
|
||||
fields:
|
||||
@@ -7293,6 +7302,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: keyring
|
||||
type:
|
||||
scalar: string
|
||||
default: /etc/ceph/keyring
|
||||
- name: monitors
|
||||
type:
|
||||
list:
|
||||
@@ -7302,6 +7312,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: pool
|
||||
type:
|
||||
scalar: string
|
||||
default: rbd
|
||||
- name: readOnly
|
||||
type:
|
||||
scalar: boolean
|
||||
@@ -7311,6 +7322,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: user
|
||||
type:
|
||||
scalar: string
|
||||
default: admin
|
||||
- name: io.k8s.api.core.v1.ReplicationController
|
||||
map:
|
||||
fields:
|
||||
@@ -7511,6 +7523,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: fsType
|
||||
type:
|
||||
scalar: string
|
||||
default: xfs
|
||||
- name: gateway
|
||||
type:
|
||||
scalar: string
|
||||
@@ -7530,6 +7543,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: storageMode
|
||||
type:
|
||||
scalar: string
|
||||
default: ThinProvisioned
|
||||
- name: storagePool
|
||||
type:
|
||||
scalar: string
|
||||
@@ -7546,6 +7560,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: fsType
|
||||
type:
|
||||
scalar: string
|
||||
default: xfs
|
||||
- name: gateway
|
||||
type:
|
||||
scalar: string
|
||||
@@ -7565,6 +7580,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
- name: storageMode
|
||||
type:
|
||||
scalar: string
|
||||
default: ThinProvisioned
|
||||
- name: storagePool
|
||||
type:
|
||||
scalar: string
|
||||
|
||||
Reference in New Issue
Block a user