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

kola/kubeadm: test various CNIs #182

Merged
merged 2 commits into from
Jul 29, 2021

Conversation

tormath1
Copy link
Contributor

@tormath1 tormath1 commented Jul 1, 2021

In this PR, we try to cover more kubernetes use cases by testing different CNIs.

  • flannel
  • calico
  • cilium

How to use

$ ./bin/kola list | grep kubeadm
kubeadm.calico.base			[aws azure do gce openstack packet qemu qemu-unpriv]	[all]		[cl]		[all]			[all]
kubeadm.cilium.base			[aws azure do gce openstack packet qemu qemu-unpriv]	[all]		[cl]		[all]			[all]
kubeadm.flannel.base			[aws azure do gce openstack packet qemu qemu-unpriv]	[all]		[cl]		[all]			[all]
$ sudo ./bin/kola run -b cl -p qemu --qemu-image ./flatcar_production_qemu_image.img kubeadm.flannel.base

closes: flatcar/Flatcar#309

@tormath1 tormath1 self-assigned this Jul 1, 2021
@tormath1 tormath1 added the enhancement New feature or request label Jul 1, 2021
@tormath1 tormath1 force-pushed the tormath1/kubeadm-add-flannel branch 3 times, most recently from 4500370 to 6d604ee Compare July 6, 2021 09:53
@tormath1 tormath1 marked this pull request as ready for review July 6, 2021 15:07
@tormath1 tormath1 requested a review from a team July 6, 2021 15:08
@tormath1 tormath1 changed the title [wip] kola/kubeadm: test various CNIs kola/kubeadm: test various CNIs Jul 6, 2021
kubectl create -f https://docs.projectcalico.org/manifests/tigera-operator.yaml
kubectl apply -f calico.yaml
{{ end }}
{{ if eq .CNI "flannel" }}
curl -sSL https://github.com/raw/flannel-io/flannel/master/Documentation/kube-flannel.yml > kube-flannel.yml
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
curl -sSL https://raw.githubusercontent.com/flannel-io/flannel/master/Documentation/kube-flannel.yml > kube-flannel.yml
curl -sSfL https://raw.githubusercontent.com/flannel-io/flannel/master/Documentation/kube-flannel.yml > kube-flannel.yml

We should fail on 404




curl -sSL https://github.com/raw/flannel-io/flannel/master/Documentation/kube-flannel.yml > kube-flannel.yml
Copy link
Member

Choose a reason for hiding this comment

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

same

Copy link
Member

@pothos pothos left a comment

Choose a reason for hiding this comment

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

Two small issues with fetching via curl but otherwise feel free to merge

@tormath1
Copy link
Contributor Author

thanks @pothos for reviewing. Comments have been addressed. FYI kola/tests/kubeadm/testdata/master-flannel-script.sh is just a testdata to assert master script is well generated from the template.

Once the CI 🟢 I'll rebase and merge.

Mathieu Tortuyaux added 2 commits July 29, 2021 11:43
this commit adds logic and templates to test more CNIs in a
kubernetes context.

- calico
- flannel
- cilium

Tests have a common implementation but it differs using templates
following the tested CNI

Signed-off-by: Mathieu Tortuyaux <mathieu@kinvolk.io>
this testdata will assert that the installation scripts
are well rendered following the CNI, it also allows to help
reproduce issues with the tests using directly the testdata

Signed-off-by: Mathieu Tortuyaux <mathieu@kinvolk.io>
@tormath1 tormath1 force-pushed the tormath1/kubeadm-add-flannel branch from 708bf9d to 11d3514 Compare July 29, 2021 09:44
@tormath1 tormath1 merged commit aa325bc into flatcar-master Jul 29, 2021
@tormath1 tormath1 deleted the tormath1/kubeadm-add-flannel branch July 29, 2021 09:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add tests for more CNIs
2 participants