Skip to content

Commit

Permalink
Merge pull request #11272 from hakman/automated-cherry-pick-of-#11271…
Browse files Browse the repository at this point in the history
…-upstream-release-1.20

Automated cherry pick of #11271: Add Azure image to alpha/stable channel
  • Loading branch information
k8s-ci-robot committed Apr 20, 2021
2 parents 230c40b + 3e06e06 commit 09f8590
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
3 changes: 2 additions & 1 deletion pkg/apis/kops/channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -335,5 +335,6 @@ func (c *Channel) HasUpstreamImagePrefix(image string) bool {
return strings.HasPrefix(image, "kope.io/k8s-") ||
strings.HasPrefix(image, "099720109477/ubuntu/images/hvm-ssd/ubuntu-focal-20.04-") ||
strings.HasPrefix(image, "cos-cloud/cos-stable-") ||
strings.HasPrefix(image, "ubuntu-os-cloud/ubuntu-")
strings.HasPrefix(image, "ubuntu-os-cloud/ubuntu-") ||
strings.HasPrefix(image, "Canonical:UbuntuServer:")
}
7 changes: 2 additions & 5 deletions upup/pkg/fi/cloudup/populate_instancegroup_spec.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,8 @@ const (
defaultMasterMachineTypeALI = "ecs.n2.medium"
defaultMasterMachineTypeAzure = "Standard_B2ms"

defaultDONodeImage = "ubuntu-20-04-x64"
defaultALINodeImage = "centos_7_04_64_20G_alibase_201701015.vhd"
defaultAzureNodeImage = "Canonical:UbuntuServer:20.04-LTS:latest"
defaultDONodeImage = "ubuntu-20-04-x64"
defaultALINodeImage = "centos_7_04_64_20G_alibase_201701015.vhd"
)

// TODO: this hardcoded list can be replaced with DescribeInstanceTypes' DedicatedHostsSupported field
Expand Down Expand Up @@ -254,8 +253,6 @@ func defaultImage(cluster *kops.Cluster, channel *kops.Channel, architecture arc
return defaultDONodeImage
case kops.CloudProviderALI:
return defaultALINodeImage
case kops.CloudProviderAzure:
return defaultAzureNodeImage
}
klog.Infof("Cannot set default Image for CloudProvider=%q", cluster.Spec.CloudProvider)
return ""
Expand Down

0 comments on commit 09f8590

Please sign in to comment.