Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: kubernetes-sigs/cluster-api-provider-openstack
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 89ade64af04247f75c81ce4c52bcd8f2934d5b80
Choose a base ref
..
head repository: kubernetes-sigs/cluster-api-provider-openstack
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 9164abeede35509541150392e606811ce387620e
Choose a head ref
Showing with 5 additions and 2 deletions.
  1. +5 −2 pkg/cloud/openstack/services/userdata/kubeadm.go
7 changes: 5 additions & 2 deletions pkg/cloud/openstack/services/userdata/kubeadm.go
Original file line number Diff line number Diff line change
@@ -50,6 +50,9 @@ func generateKubeadmConfig(isControlPlane bool, bootstrapToken string, machine *
if string(clusterConfigurationCopy.DNS.Type) == "" {
clusterConfigurationCopy.DNS.Type = kubeadmv1beta1.CoreDNS
}
if clusterConfigurationCopy.ImageRepository == "" {
clusterConfigurationCopy.ImageRepository = kubeadmv1beta1.DefaultImageRepository
}
kubeadm.SetClusterConfigurationOptions(
clusterConfigurationCopy,
kubeadm.WithKubernetesVersion(*machine.Spec.Version),
@@ -106,7 +109,7 @@ func generateKubeadmConfig(isControlPlane bool, bootstrapToken string, machine *
joinConfigurationCopy := openStackMachine.Spec.KubeadmConfiguration.Join
// Set default values. If they are not set, these two properties are added with an
// empty string and the CoreOS ignition postprocesser fails with "could not find expected key"
joinConfigurationCopy.CACertPath = kubeadmv1beta1.DefaultCertificatesDir
joinConfigurationCopy.CACertPath = kubeadmv1beta1.DefaultCACertPath
kubeadm.SetJoinConfigurationOptions(
&joinConfigurationCopy,
kubeadm.WithBootstrapTokenDiscovery(
@@ -139,7 +142,7 @@ func generateKubeadmConfig(isControlPlane bool, bootstrapToken string, machine *
joinConfigurationCopy := openStackMachine.Spec.KubeadmConfiguration.Join
// Set default values. If they are not set, these two properties are added with an
// empty string and the CoreOS ignition postprocesser fails with "could not find expected key"
joinConfigurationCopy.CACertPath = kubeadmv1beta1.DefaultCertificatesDir
joinConfigurationCopy.CACertPath = kubeadmv1beta1.DefaultCACertPath
kubeadm.SetJoinConfigurationOptions(
&joinConfigurationCopy,
kubeadm.WithBootstrapTokenDiscovery(