From 9713558477d2fdaa9e4d68cda65c36fb98f64a60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabiano=20Fid=C3=AAncio?= Date: Sat, 11 May 2024 23:18:20 +0200 Subject: [PATCH] k0s: Use a different port for kube-route's metrics MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit kube-router decided to use :8080 for its metrics, and this seems to be a change that affected k0s 1.30.0+, leading to kube-router pod crashing all the time and anything can actually be started after that. Due to this issue, let's simply use a different port (:9999) and move on with our tests. Fixes: #9623 Signed-off-by: Fabiano FidĂȘncio --- tests/gha-run-k8s-common.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tests/gha-run-k8s-common.sh b/tests/gha-run-k8s-common.sh index 9971174485..3b3a580ed6 100644 --- a/tests/gha-run-k8s-common.sh +++ b/tests/gha-run-k8s-common.sh @@ -193,6 +193,17 @@ function deploy_k0s() { sudo k0s install controller --single ${KUBERNETES_EXTRA_PARAMS:-} + # kube-router decided to use :8080 for its metrics, and this seems + # to be a change that affected k0s 1.30.0+, leading to kube-router + # pod crashing all the time and anything can actually be started + # after that. + # + # Due to this issue, let's simply use a different port (:9999) and + # move on with our tests. + sudo mkdir -p /etc/k0s + k0s config create | sudo tee /etc/k0s/k0s.yaml + sudo sed -i -e "s/metricsPort: 8080/metricsPort: 9999/g" /etc/k0s/k0s.yaml + sudo k0s start # This is an arbitrary value that came up from local tests