cozystack/hack
Andrei Kvapil 21715c02bc
The Cozystack Kubernetes tests are now POSIX-compatible (#1509)
This patch replaces bash-specific [[ ... ]] expressions in the
run_kubernetes_test function with POSIX-compliant case and test
constructs. It ensures that the Kubernetes version on each worker node
is verified correctly and that required components (CoreDNS, Cilium,
ingress-nginx, vsnap-crd) are ready before proceeding. Now the tests
work reliably even when executed with /bin/sh, such as in Bats.

```release-note
[tests] Make Kubernetes tests POSIX-compliant and more reliable:
verify worker node versions and ensure required releases (CoreDNS,
Cilium, ingress-nginx, vsnap-crd) are installed and ready.
```

<!-- Thank you for making a contribution! Here are some tips for you:
- Start the PR title with the [label] of Cozystack component:
- For system components: [platform], [system], [linstor], [cilium],
[kube-ovn], [dashboard], [cluster-api], etc.
- For managed apps: [apps], [tenant], [kubernetes], [postgres],
[virtual-machine] etc.
- For development and maintenance: [tests], [ci], [docs], [maintenance].
- If it's a work in progress, consider creating this PR as a draft.
- Don't hesistate to ask for opinion and review in the community chats,
even if it's still a draft.
- Add the label `backport` if it's a bugfix that needs to be backported
to a previous version.
-->

## What this PR does


### Release note

<!--  Write a release note:
- Explain what has changed internally and for users.
- Start with the same [label] as in the PR title
- Follow the guidelines at
https://github.com/kubernetes/community/blob/master/contributors/guide/release-notes.md.
-->

```release-note
[]
```

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved Kubernetes version detection to correctly handle 1.32
variants.
* Made node readiness checks more reliable to reduce false failures
during runs.

* **Refactor**
* Streamlined version matching logic for clearer, more predictable
behavior across releases.

* **Style**
  * Minor formatting cleanups with no functional impact.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-13 15:02:18 +02:00
..
e2e-apps The Cozystack Kubernetes tests are now POSIX-compatible (#1509) 2025-10-13 15:02:18 +02:00
boilerplate.go.txt Introduce cozystack-controller (#560) 2025-01-09 12:24:51 +01:00
cdi_golden_image_create.sh [virtual-machine] Refactor golden images 2025-07-03 13:33:44 +03:00
collect-images.sh [dx] Refactor collect-images functionality 2025-07-03 14:26:56 +03:00
cozyreport.sh [ci] Fix garbage output in cozyreport 2025-09-04 11:03:08 +03:00
cozytest.sh [tests] Add more space for e2e tests 2025-08-11 13:04:00 +03:00
download-dashboards.sh [monitoring] add seaweedfs monitoring 2025-07-30 15:17:46 +03:00
e2e-install-cozystack.bats add resource quota for testing ns 2025-09-09 17:42:52 +03:00
e2e-prepare-cluster.bats [talos] Add lldpd extension to image 2025-08-26 11:10:23 +03:00
e2e-test-openapi.bats Add test for openapi schema 2025-08-21 16:51:21 +02:00
pre-checks.sh Fix osx grep have no -P flag (#438) 2024-10-21 11:59:56 +02:00
update-codegen.sh [installer] Even more rigorous migration 2025-10-09 21:34:14 +03:00
update-crd.sh [api,platform] Decouple CozyRDs from API HR 2025-10-08 16:18:47 +03:00
upload-assets.sh Upload kernel and initramfs to release assets 2025-04-08 23:27:37 +02:00