-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[cluster-autoscaler-release-1.28] Backporting support for Regional Instance Template GCE to 1.29 #7409
Conversation
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: k8s-infra-cherrypick-robot, x13n The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@@ -73,6 +73,11 @@ func GenerateMigUrl(ref GceRef) string { | |||
return fmt.Sprintf(migUrlTemplate, ref.Project, ref.Zone, ref.Name) | |||
} | |||
|
|||
// IsInstanceTemplateRegional determines whether or not an instance template is regional based on the url | |||
func IsInstanceTemplateRegional(templateUrl string) (bool, error) { | |||
return regexp.MatchString("(/projects/.*[A-Za-z0-9]+.*/regions/)", templateUrl) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Failing tests: We need to add the regexp import as it doesn't exist in this file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, thanks! Added the missing import.
Add missing import.
Hm... not sure if I can still LGTM after adding my own commit to fix missing import, but let's try: /lgtm |
6a3cf22
into
kubernetes:cluster-autoscaler-release-1.28
I was also surprised to discover that this works the other day! |
This is an automated cherry-pick of #7231
/assign x13n