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

Fix test environment on GKE #5207

Merged
merged 4 commits into from
Aug 16, 2022
Merged

Conversation

antgamdia
Copy link
Contributor

@antgamdia antgamdia commented Aug 11, 2022

Description of the change

The local registry setup for the e2e test is not working on GKE. While finding a way to create a local registry there (main issue is dealing with certs), it's ok with disabling this test (and its setup) for now. This PR is moving the 10-xxx test into the multicluster folder (which is not run when on GKE).

Plus: using a clusterrolebinding for allowing listing repos from ns="" in the EDIT user in CI

Benefits

GKE tests (and therefore the release) will pass.

Possible drawbacks

N/A

Applicable issues

N/A

Additional information

N/A

@netlify
Copy link

netlify bot commented Aug 11, 2022

Deploy Preview for kubeapps-dev canceled.

Built without sensitive environment variables

Name Link
🔨 Latest commit a7714fe
🔍 Latest deploy log https://app.netlify.com/sites/kubeapps-dev/deploys/62fb826d9296ce0009917164

@antgamdia antgamdia changed the title Install mkcert on gke tests Fix test environment on GKE Aug 11, 2022
Signed-off-by: Antonio Gamez Diaz <agamez@vmware.com>
Signed-off-by: Antonio Gamez Diaz <agamez@vmware.com>
Signed-off-by: Antonio Gamez Diaz <agamez@vmware.com>
Signed-off-by: Antonio Gamez Diaz <agamez@vmware.com>
@antgamdia
Copy link
Contributor Author

Tested and working in pre-release:

image

Comment on lines +312 to +316
# Setting up local Docker registry if not in GKE
if [[ -z "${GKE_BRANCH-}" ]]; then
setupLocalDockerRegistry
pushLocalChart
fi
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The local docker registry doesn't work right now on GKE as the current configuration requires the k8s cert to be copied for issuing the certs. The quickest solution: ignore those tests when in GKE.

@@ -396,7 +398,7 @@ kubectl create serviceaccount kubeapps-edit -n kubeapps
# default). See https://github.com/vmware-tanzu/kubeapps/issues/4435
kubectl create rolebinding kubeapps-edit -n kubeapps --clusterrole=edit --serviceaccount kubeapps:kubeapps-edit
kubectl create rolebinding kubeapps-edit -n default --clusterrole=edit --serviceaccount kubeapps:kubeapps-edit
kubectl create rolebinding kubeapps-repositories-read -n kubeapps --clusterrole kubeapps:kubeapps:apprepositories-read --serviceaccount kubeapps:kubeapps-edit
kubectl create clusterrolebinding kubeapps-repositories-read --clusterrole kubeapps:kubeapps:apprepositories-read --serviceaccount kubeapps:kubeapps-edit
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changing to clusterrolebinding instead for allowing listing repos when using namespace=""
Issue tracked at #5215

@antgamdia antgamdia merged commit 412f63b into vmware-tanzu:main Aug 16, 2022
@antgamdia antgamdia deleted the mkcert-gke branch August 16, 2022 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants