Skip to content

Commit 403fbd8

Browse files
authored
Merge pull request #2163 from CecileRobertMichon/kubeadm-verbose
✨ Add verbosity to kubeadm config
2 parents 8ad19cf + 6907d45 commit 403fbd8

12 files changed

+1675
-758
lines changed

bootstrap/kubeadm/api/v1alpha2/conversion.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ func (src *KubeadmConfig) ConvertTo(dstRaw conversion.Hub) error {
3737
}
3838

3939
dst.Status.DataSecretName = restored.Status.DataSecretName
40+
dst.Spec.Verbosity = restored.Spec.Verbosity
4041

4142
return nil
4243
}
@@ -117,3 +118,14 @@ func Convert_v1alpha3_KubeadmConfigStatus_To_v1alpha2_KubeadmConfigStatus(in *ku
117118

118119
return nil
119120
}
121+
122+
123+
// Convert_v1alpha2_KubeadmConfigSpec_To_v1alpha3_KubeadmConfigSpec converts this KubeadmConfigSpec to the Hub version (v1alpha3).
124+
func Convert_v1alpha2_KubeadmConfigSpec_To_v1alpha3_KubeadmConfigSpec(in *KubeadmConfigSpec, out *kubeadmbootstrapv1alpha3.KubeadmConfigSpec, s apiconversion.Scope) error {
125+
return autoConvert_v1alpha2_KubeadmConfigSpec_To_v1alpha3_KubeadmConfigSpec(in, out, s)
126+
}
127+
128+
// Convert_v1alpha3_KubeadmConfigSpec_To_v1alpha2_KubeadmConfigSpec converts from the Hub version (v1alpha3) of the KubeadmConfigSpec to this version.
129+
func Convert_v1alpha3_KubeadmConfigSpec_To_v1alpha2_KubeadmConfigSpec(in *kubeadmbootstrapv1alpha3.KubeadmConfigSpec, out *KubeadmConfigSpec, s apiconversion.Scope) error {
130+
return autoConvert_v1alpha3_KubeadmConfigSpec_To_v1alpha2_KubeadmConfigSpec(in, out, s)
131+
}

bootstrap/kubeadm/api/v1alpha2/zz_generated.conversion.go

Lines changed: 33 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bootstrap/kubeadm/api/v1alpha3/kubeadmbootstrapconfig_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,11 @@ type KubeadmConfigSpec struct {
6868
// Format specifies the output format of the bootstrap data
6969
// +optional
7070
Format Format `json:"format,omitempty"`
71+
72+
// Verbosity is the number for the kubeadm log level verbosity.
73+
// It overrides the `--v` flag in kubeadm commands.
74+
// +optional
75+
Verbosity *int32 `json:"verbosity,omitempty"`
7176
}
7277

7378
// KubeadmConfigStatus defines the observed state of KubeadmConfig

bootstrap/kubeadm/api/v1alpha3/zz_generated.deepcopy.go

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bootstrap/kubeadm/config/crd/bases/bootstrap.cluster.x-k8s.io_kubeadmconfigs.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1606,6 +1606,11 @@ spec:
16061606
- name
16071607
type: object
16081608
type: array
1609+
verbosity:
1610+
description: Verbosity is the number for the kubeadm log level verbosity.
1611+
It overrides the `--v` flag in kubeadm commands.
1612+
format: int32
1613+
type: integer
16091614
type: object
16101615
status:
16111616
description: KubeadmConfigStatus defines the observed state of KubeadmConfig

0 commit comments

Comments
 (0)