diff --git a/acceptance/deploy.sh b/acceptance/deploy.sh index 20714009..7beb5338 100755 --- a/acceptance/deploy.sh +++ b/acceptance/deploy.sh @@ -54,6 +54,7 @@ if [ "${tool}" == "helm" ]; then --set imagePullSecrets[0].name=${IMAGE_PULL_SECRET} \ --set image.actionsRunnerImagePullSecrets[0].name=${IMAGE_PULL_SECRET} \ --set githubWebhookServer.imagePullSecrets[0].name=${IMAGE_PULL_SECRET} \ + --set image.imagePullPolicy=${IMAGE_PULL_POLICY} \ -f ${VALUES_FILE} set +v # To prevent `CustomResourceDefinition.apiextensions.k8s.io "runners.actions.summerwind.dev" is invalid: metadata.annotations: Too long: must have at most 262144 bytes` diff --git a/test/e2e/e2e_test.go b/test/e2e/e2e_test.go index 5658b507..2bd126a9 100644 --- a/test/e2e/e2e_test.go +++ b/test/e2e/e2e_test.go @@ -254,6 +254,7 @@ type env struct { dockerdWithinRunnerContainer bool remoteKubeconfig string imagePullSecretName string + imagePullPolicy string vars vars VerifyTimeout time.Duration @@ -367,6 +368,12 @@ func initTestEnv(t *testing.T, k8sMinorVer string, vars vars) *env { e.imagePullSecretName = testing.Getenv(t, "ARC_E2E_IMAGE_PULL_SECRET_NAME", "") e.vars = vars + if e.remoteKubeconfig != "" { + e.imagePullPolicy = "Always" + } else { + e.imagePullPolicy = "IfNotPresent" + } + if e.remoteKubeconfig == "" { e.Kind = testing.StartKind(t, k8sMinorVer, testing.Preload(images...)) e.Env.Kubeconfig = e.Kind.Kubeconfig() @@ -457,6 +464,7 @@ func (e *env) installActionsRunnerController(t *testing.T, repo, tag, testID str "NAME=" + repo, "VERSION=" + tag, "IMAGE_PULL_SECRET=" + e.imagePullSecretName, + "IMAGE_PULL_POLICY=" + e.imagePullPolicy, } if e.useApp {