Skip to content

Commit

Permalink
🐛 mark defaulted fields as optional
Browse files Browse the repository at this point in the history
Add optional tags for fields that have defaults provided elsewhere (in the bootstrap provider, or kubeadm itself).
  • Loading branch information
sethp-nr committed Mar 16, 2020
1 parent 47eeca0 commit 7090b93
Show file tree
Hide file tree
Showing 4 changed files with 120 additions and 53 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,9 @@ spec:
values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
certificatesDir:
description: CertificatesDir specifies where to store or look
for all required certificates.
description: 'CertificatesDir specifies where to store or look
for all required certificates. NB: if not provided, this will
default to `/etc/kubernetes/pki`'
type: string
clusterName:
description: The cluster name
Expand Down Expand Up @@ -187,7 +188,8 @@ spec:
type: string
type: object
etcd:
description: Etcd holds configuration for etcd.
description: 'Etcd holds configuration for etcd. NB: This value
defaults to a Local (stacked) etcd'
properties:
external:
description: External describes how to connect to an external
Expand Down Expand Up @@ -292,14 +294,16 @@ spec:
Defaults to "cluster.local".
type: string
podSubnet:
description: PodSubnet is the subnet used by pods.
description: PodSubnet is the subnet used by pods. If unset,
the API server will not allocate CIDR ranges for every node.
Defaults to the first element of the Cluster object's spec.clusterNetwork.services.cidrBlocks
if that is set
type: string
serviceSubnet:
description: ServiceSubnet is the subnet used by k8s services.
Defaults to "10.96.0.0/12".
Defaults to the first element of the Cluster object's spec.clusterNetwork.pods.cidrBlocks
field, or to "10.96.0.0/12" if that's unset.
type: string
required:
- podSubnet
type: object
scheduler:
description: Scheduler contains extra settings for the scheduler
Expand Down Expand Up @@ -720,8 +724,6 @@ spec:
type: object
type: array
type: object
required:
- nodeRegistration
type: object
ntp:
description: NTP specifies NTP configuration
Expand Down Expand Up @@ -907,8 +909,9 @@ spec:
values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
certificatesDir:
description: CertificatesDir specifies where to store or look
for all required certificates.
description: 'CertificatesDir specifies where to store or look
for all required certificates. NB: if not provided, this will
default to `/etc/kubernetes/pki`'
type: string
clusterName:
description: The cluster name
Expand Down Expand Up @@ -990,7 +993,8 @@ spec:
type: string
type: object
etcd:
description: Etcd holds configuration for etcd.
description: 'Etcd holds configuration for etcd. NB: This value
defaults to a Local (stacked) etcd'
properties:
external:
description: External describes how to connect to an external
Expand Down Expand Up @@ -1095,14 +1099,16 @@ spec:
Defaults to "cluster.local".
type: string
podSubnet:
description: PodSubnet is the subnet used by pods.
description: PodSubnet is the subnet used by pods. If unset,
the API server will not allocate CIDR ranges for every node.
Defaults to the first element of the Cluster object's spec.clusterNetwork.services.cidrBlocks
if that is set
type: string
serviceSubnet:
description: ServiceSubnet is the subnet used by k8s services.
Defaults to "10.96.0.0/12".
Defaults to the first element of the Cluster object's spec.clusterNetwork.pods.cidrBlocks
field, or to "10.96.0.0/12" if that's unset.
type: string
required:
- podSubnet
type: object
scheduler:
description: Scheduler contains extra settings for the scheduler
Expand Down Expand Up @@ -1523,8 +1529,6 @@ spec:
type: object
type: array
type: object
required:
- nodeRegistration
type: object
ntp:
description: NTP specifies NTP configuration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,9 @@ spec:
and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
certificatesDir:
description: CertificatesDir specifies where to store
or look for all required certificates.
description: 'CertificatesDir specifies where to store
or look for all required certificates. NB: if not provided,
this will default to `/etc/kubernetes/pki`'
type: string
clusterName:
description: The cluster name
Expand Down Expand Up @@ -201,7 +202,8 @@ spec:
type: string
type: object
etcd:
description: Etcd holds configuration for etcd.
description: 'Etcd holds configuration for etcd. NB: This
value defaults to a Local (stacked) etcd'
properties:
external:
description: External describes how to connect to
Expand Down Expand Up @@ -314,13 +316,17 @@ spec:
type: string
podSubnet:
description: PodSubnet is the subnet used by pods.
If unset, the API server will not allocate CIDR
ranges for every node. Defaults to the first element
of the Cluster object's spec.clusterNetwork.services.cidrBlocks
if that is set
type: string
serviceSubnet:
description: ServiceSubnet is the subnet used by k8s
services. Defaults to "10.96.0.0/12".
services. Defaults to the first element of the Cluster
object's spec.clusterNetwork.pods.cidrBlocks field,
or to "10.96.0.0/12" if that's unset.
type: string
required:
- podSubnet
type: object
scheduler:
description: Scheduler contains extra settings for the
Expand Down Expand Up @@ -764,8 +770,6 @@ spec:
type: object
type: array
type: object
required:
- nodeRegistration
type: object
ntp:
description: NTP specifies NTP configuration
Expand Down Expand Up @@ -947,8 +951,9 @@ spec:
and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
certificatesDir:
description: CertificatesDir specifies where to store
or look for all required certificates.
description: 'CertificatesDir specifies where to store
or look for all required certificates. NB: if not provided,
this will default to `/etc/kubernetes/pki`'
type: string
clusterName:
description: The cluster name
Expand Down Expand Up @@ -1035,7 +1040,8 @@ spec:
type: string
type: object
etcd:
description: Etcd holds configuration for etcd.
description: 'Etcd holds configuration for etcd. NB: This
value defaults to a Local (stacked) etcd'
properties:
external:
description: External describes how to connect to
Expand Down Expand Up @@ -1148,13 +1154,17 @@ spec:
type: string
podSubnet:
description: PodSubnet is the subnet used by pods.
If unset, the API server will not allocate CIDR
ranges for every node. Defaults to the first element
of the Cluster object's spec.clusterNetwork.services.cidrBlocks
if that is set
type: string
serviceSubnet:
description: ServiceSubnet is the subnet used by k8s
services. Defaults to "10.96.0.0/12".
services. Defaults to the first element of the Cluster
object's spec.clusterNetwork.pods.cidrBlocks field,
or to "10.96.0.0/12" if that's unset.
type: string
required:
- podSubnet
type: object
scheduler:
description: Scheduler contains extra settings for the
Expand Down Expand Up @@ -1598,8 +1608,6 @@ spec:
type: object
type: array
type: object
required:
- nodeRegistration
type: object
ntp:
description: NTP specifies NTP configuration
Expand Down
Loading

0 comments on commit 7090b93

Please sign in to comment.