Skip to content

Commit

Permalink
Merge pull request #8230 from kadern0/issue-8210
Browse files Browse the repository at this point in the history
Fixed error parsing old version "latest" or "stable"
  • Loading branch information
medyagh authored May 21, 2020
2 parents 25045cf + 6189206 commit eea26ea
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion cmd/minikube/cmd/start_flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,14 @@ func updateExistingConfigFromFlags(cmd *cobra.Command, existing *config.ClusterC
}

if cmd.Flags().Changed(kubernetesVersion) {
cc.KubernetesConfig.KubernetesVersion = viper.GetString(kubernetesVersion)
switch viper.GetString(kubernetesVersion) {
case "latest":
existing.KubernetesConfig.KubernetesVersion = constants.NewestKubernetesVersion
case "stable":
existing.KubernetesConfig.KubernetesVersion = constants.DefaultKubernetesVersion
default:
existing.KubernetesConfig.KubernetesVersion = viper.GetString(kubernetesVersion)
}
}

if cmd.Flags().Changed(apiServerName) {
Expand Down

0 comments on commit eea26ea

Please sign in to comment.