Skip to content

[k8s] Fix `testKubernetesWithNonRootSecurityContext` integration tests

Hannes Hörl requested to merge hhoerl/k8s-e2e-let-git-write into main

What does this MR do?

[k8s] Fix testKubernetesWithNonRootSecurityContext integration tests

These tests seem to work alright, but the fact that we are not running as root, git can't write its config and falls over. Thus, we just set $HOME to something writeable.

Also, I didn't find any evidence that this test is not able to run on minikube; over here¹ it just works™.

¹

: uname -r -o -s --hardware-platform
Linux 6.8.0-38-generic x86_64 GNU/Linux
: minikube version
minikube version: v1.33.1
commit: 5883c09216182566a63dff4c326a6fc9ed2982ff
:

Why was this MR needed?

To fix them tests!

What's the best way to test this MR?

go test -count=1 -tags=kubernetes,integration -v -run 'TestRunIntegrationTestsWithFeatureFlag/testKubernetesWithNonRootSecurityContext_FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY/testKubernetesWithNonRootSecurityContext_FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY_(true|false)' ./executors/kubernetes/

What are the relevant issue numbers?

n/a

Edited by Hannes Hörl

Merge request reports

Loading