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

test: remove legacy Windows dockershim templates #2292

Merged

Conversation

jackfrancis
Copy link
Contributor

@jackfrancis jackfrancis commented May 9, 2022

What type of PR is this?

/kind cleanup
/kind deprecation

What this PR does / why we need it:

This PR updates the Windows test templates surface area in the following ways:

  1. Remove the E2E test job that validates Windows + dockershim cluster scenario. For capz development going forward, we no longer want to recommend users create clusters w/ Windows nodes running dockershim as the next release of capz will occur after 1.21 (the last version of Kubernetes recommended for Windows + dockershim) has reached its end-of-life.
  2. Preserve the existing "windows" templates and convert them to use containerd. The templates/test/dev/cluster-template-custom-builds.yaml template still uses the vanilla "windows" template as its base, and we can still benefit by referencing a simple template that includes a Windows AzureMachineTemplate for users.
  3. Remove the ci-conformance dockershim testing surface area (this azure: remove Windows + dockershim conformance test job kubernetes/test-infra#26242 PR does the rest of this work
  4. Ensure that all remaining Windows node-providing templates use containerd as CRI

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #

Special notes for your reviewer:

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

TODOs:

  • squashed commits
  • includes documentation
  • adds unit tests

Release note:

remove dockershim- and containerd-specific reference templates, standardize to containerd by default

@k8s-ci-robot k8s-ci-robot added kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. release-note-none Denotes a PR that doesn't merit a release note. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels May 9, 2022
@k8s-ci-robot k8s-ci-robot requested review from alexeldeib and Jont828 May 9, 2022 19:00
@jackfrancis
Copy link
Contributor Author

/test pull-cluster-api-provider-azure-e2e-optional

Copy link
Contributor

@CecileRobertMichon CecileRobertMichon left a comment

Choose a reason for hiding this comment

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

@jsturtevant can confirm but there might also be some possible cleanup around the CNI area? Since Windows containerd tests use calico and we no longer need the special flannel CNI for windows setup

Copy link
Contributor

@jsturtevant jsturtevant left a comment

Choose a reason for hiding this comment

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

This brings up an issue if we need to retain the https://github.com/kubernetes-sigs/cluster-api-provider-azure/releases/download/v1.3.0/cluster-template-windows-containerd.yaml or if it can just be renamed to cluster-template-windows.yaml.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label May 14, 2022
@jackfrancis jackfrancis force-pushed the windows-dockershim-test branch from 984602d to 8260e48 Compare May 16, 2022 19:24
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 16, 2022
@jackfrancis
Copy link
Contributor Author

@jsturtevant PTAL

@jackfrancis
Copy link
Contributor Author

/test pull-cluster-api-provider-azure-e2e-optional

Copy link
Contributor

@jsturtevant jsturtevant left a comment

Choose a reason for hiding this comment

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

feels good to be removing these :-)

@jsturtevant
Copy link
Contributor

can confirm but there might also be some possible cleanup around the CNI area? Since Windows containerd tests use calico and we no longer need the special flannel CNI for windows setup

Yes we can drop the files in https://github.com/kubernetes-sigs/cluster-api-provider-azure/tree/main/templates/addons/windows/flannel as they were only used for dockershim

@jackfrancis jackfrancis force-pushed the windows-dockershim-test branch from 8260e48 to 80a6ddb Compare May 17, 2022 19:57
@jackfrancis
Copy link
Contributor Author

@jsturtevant above cleanup tasks (and others discovered during) applied

@jackfrancis
Copy link
Contributor Author

/test pull-cluster-api-provider-azure-e2e-optional

@jsturtevant
Copy link
Contributor

/test pull-cluster-api-provider-azure-windows-containerd-upstream-with-ci-artifacts

@jsturtevant
Copy link
Contributor

looks like we got it all! 💯

One last open question:

Shouldn't this template be a rename of cluster-template-windows-containerd.yaml now? I wouldn't expect us to keep both side by side

This brings up an issue if we need to retain the https://github.com/kubernetes-sigs/cluster-api-provider-azure/releases/download/v1.3.0/cluster-template-windows-containerd.yaml or if it can just be renamed to cluster-template-windows.yaml.

It will be a breaking change to not publish cluster-template-windows-containerd.yaml in the 1.4.0 release. It already is breaking change to have cluster-template-windows.yaml go from dockershim to containerd. So this maybe ok. The other alternative I can think of is to do a symlink for one release of cluster-template-windows.yaml to cluster-template-windows-containerd.yaml in

.PHONY: release-templates
release-templates: $(RELEASE_DIR)
cp templates/cluster-template* $(RELEASE_DIR)/
that would give anyone using it a chance to move on the release.

Either way we should make sure the release notes are clear this is a breaking change in the release notes.

thoughts @jackfrancis @CecileRobertMichon ?

@jackfrancis
Copy link
Contributor Author

@jsturtevant I vote we move forward with the template name change. For folks who want to insist on retaining a canonical template under that name going forward, they can refer to an immutable link such as this one:

I will update release notes so that it gets a call-out at release time.

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note-none Denotes a PR that doesn't merit a release note. labels May 18, 2022
@@ -165,10 +163,6 @@ providers:
targetName: "cluster-template-conformance-presubmit-artifacts.yaml"
- sourcePath: "${PWD}/templates/test/dev/cluster-template-custom-builds.yaml"
targetName: "cluster-template-conformance-presubmit-artifacts-windows-containerd.yaml"
Copy link
Contributor

Choose a reason for hiding this comment

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

not related to this change but @jsturtevant do you know why we're writing the cluster-template-custom-builds.yaml template above twice with two different names?

Copy link
Contributor

Choose a reason for hiding this comment

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

Prior to this we needed different templates for windows and so we tacked windows to the end:

if isWindows(kubetestConfigFilePath) {
flavor = flavor + "-" + getWindowsFlavor()
}

After this merged we might not need this logic anymore as we can re-use the same templates. I will create an issue to follow up on this after this merges

Copy link
Contributor

Choose a reason for hiding this comment

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

@@ -165,10 +163,6 @@ providers:
targetName: "cluster-template-conformance-presubmit-artifacts.yaml"
- sourcePath: "${PWD}/templates/test/dev/cluster-template-custom-builds.yaml"
targetName: "cluster-template-conformance-presubmit-artifacts-windows-containerd.yaml"
Copy link
Contributor

Choose a reason for hiding this comment

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

not related to this change but @jsturtevant do you know why we're writing the cluster-template-custom-builds.yaml template above twice with two different names?

- machine-pool-deployment-windows.yaml

patchesStrategicMerge:
- ../../azure-cluster-identity/azurecluster-identity-ref.yaml
- ../base-windows-containerd/kubeadm-control-plane.yaml
Copy link
Contributor

Choose a reason for hiding this comment

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

should we rename this to just base-windows?

Copy link
Contributor

Choose a reason for hiding this comment

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

should we do this as part of #2315

- machine-pool-deployment-windows.yaml

patchesStrategicMerge:
- ../../azure-cluster-identity/azurecluster-identity-ref.yaml
- ../base-windows-containerd/kubeadm-control-plane.yaml
Copy link
Contributor

Choose a reason for hiding this comment

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

should we rename this to just base-windows?

@@ -155,8 +155,6 @@ providers:
targetName: "cluster-template-private.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version.yaml"
targetName: "cluster-template-conformance-ci-artifacts.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version-windows.yaml"
targetName: "cluster-template-conformance-ci-artifacts-windows.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version-windows-containerd-2022.yaml"
targetName: "cluster-template-conformance-ci-artifacts-windows-containerd-2022.yaml"
Copy link
Contributor

Choose a reason for hiding this comment

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

can we also rename cluster-template-prow-ci-version-windows-containerd-2022 to cluster-template-prow-ci-version-windows-2022 ?

@@ -155,8 +155,6 @@ providers:
targetName: "cluster-template-private.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version.yaml"
targetName: "cluster-template-conformance-ci-artifacts.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version-windows.yaml"
targetName: "cluster-template-conformance-ci-artifacts-windows.yaml"
- sourcePath: "${PWD}/templates/test/ci/cluster-template-prow-ci-version-windows-containerd-2022.yaml"
targetName: "cluster-template-conformance-ci-artifacts-windows-containerd-2022.yaml"
Copy link
Contributor

Choose a reason for hiding this comment

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

can we also rename cluster-template-prow-ci-version-windows-containerd-2022 to cluster-template-prow-ci-version-windows-2022 ?

Copy link
Contributor

Choose a reason for hiding this comment

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

I think this will rely on change the logic in the e2e_conformance: #2315

Lets follow up with a separate pr for that?

@jsturtevant
Copy link
Contributor

I vote we move forward with the template name change.

Ok, I think we are all in agreement

@jsturtevant
Copy link
Contributor

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 19, 2022
Copy link
Contributor

@CecileRobertMichon CecileRobertMichon left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

thank you @jackfrancis!

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: CecileRobertMichon

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 19, 2022
@k8s-ci-robot k8s-ci-robot merged commit d28d51c into kubernetes-sigs:main May 19, 2022
@k8s-ci-robot k8s-ci-robot added this to the v1.4 milestone May 19, 2022
@jackfrancis jackfrancis deleted the windows-dockershim-test branch December 9, 2022 22:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants