Skip to content
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

Upgrade kops to 1.22 #708

Merged
merged 4 commits into from
Sep 6, 2022
Merged

Upgrade kops to 1.22 #708

merged 4 commits into from
Sep 6, 2022

Conversation

stafot
Copy link
Contributor

@stafot stafot commented Aug 29, 2022

Issue: CLD-1543

Summary

Upgrade kops to 1.22

Ticket Link

https://mattermost.atlassian.net/browse/CLD-1543

Release Note

Upgrade kops to 1.22

@mm-cloud-bot mm-cloud-bot added kind/chore Categorizes issue or PR as related to updates that are not production code. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Aug 29, 2022
Comment on lines -194 to -204
k8sClient, err := k8s.NewFromFile(kops.GetKubeConfigPath(), logger)
if err != nil {
return err
}

_, err = k8sClient.UpdateStorageClassVolumeBindingMode("gp2")
if err != nil {
return err
}
logger.WithField("name", kopsMetadata.Name).Info("Successfully updated storage class")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This block fails at the moment and in my understanding of things is totally obsolete and can be safely removed. But if your understanding is different @gabrieljackson and @Szymongib feel free to correct me.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I can't remember what this was used for, but would agree that if there are no perceived issues then it should be okay to remove. The code was added by @stylianosrigas so let's check with him as well.

@stafot stafot force-pushed the chore/CLD-1543 branch 4 times, most recently from d72f5d3 to 44812b9 Compare August 29, 2022 15:31
@@ -79,11 +79,11 @@ func (c *Cmd) CreateCluster(name, cloud string, kopsRequest *model.KopsMetadataR
// Example setValue: spec.kubernetesVersion=1.10.0
func (c *Cmd) SetCluster(name, setValue string) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is another SetInstanceGroup method that should need this change: https://github.com/mattermost/mattermost-cloud/blob/master/internal/tools/kops/instance_groups.go#L221

Comment on lines -194 to -204
k8sClient, err := k8s.NewFromFile(kops.GetKubeConfigPath(), logger)
if err != nil {
return err
}

_, err = k8sClient.UpdateStorageClassVolumeBindingMode("gp2")
if err != nil {
return err
}
logger.WithField("name", kopsMetadata.Name).Info("Successfully updated storage class")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I can't remember what this was used for, but would agree that if there are no perceived issues then it should be okay to remove. The code was added by @stylianosrigas so let's check with him as well.

Issue: CLD-1543
Signed-off-by: Stavros Foteinopoulos <stafot@gmail.com>
Issue:
Signed-off-by: Stavros Foteinopoulos <stafot@gmail.com>
Issue:
Signed-off-by: Stavros Foteinopoulos <stafot@gmail.com>
@stafot stafot marked this pull request as ready for review September 1, 2022 06:36
@stafot stafot changed the title WIP: Upgrade kops to 1.22 Upgrade kops to 1.22 Sep 1, 2022
Copy link
Contributor

@gabrieljackson gabrieljackson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM as long as both a cluster resize and upgrade were performed alongside creation and deletion tests.

@stafot stafot merged commit 83000f7 into master Sep 6, 2022
@stafot stafot deleted the chore/CLD-1543 branch September 6, 2022 09:21
gabrieljackson added a commit that referenced this pull request Sep 13, 2022
stafot pushed a commit that referenced this pull request Sep 14, 2022
stafot added a commit that referenced this pull request Sep 14, 2022
stafot added a commit that referenced this pull request Sep 14, 2022
gabrieljackson added a commit that referenced this pull request Sep 22, 2022
stafot pushed a commit that referenced this pull request Sep 22, 2022
stafot added a commit that referenced this pull request Sep 23, 2022
stafot added a commit that referenced this pull request Sep 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/chore Categorizes issue or PR as related to updates that are not production code. release-note Denotes a PR that will be considered when it comes time to generate release notes.
Projects
None yet
3 participants