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(k8s): error in cleanup-cluster-registry command and added test #1772

Merged
merged 2 commits into from
May 12, 2020

Conversation

edvald
Copy link
Collaborator

@edvald edvald commented Apr 3, 2020

What this PR does / why we need it:

One step of cleaning up the cluster registry was failing, which also prevented following steps to complete. Added a test against our cluster as well, so we should catch these issues from now on.

@edvald edvald force-pushed the fix-cleanup branch 2 times, most recently from f73cbf0 to ce93f01 Compare April 4, 2020 11:51
Copy link
Collaborator

@eysi09 eysi09 left a comment

Choose a reason for hiding this comment

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

A couple of questions, otherwise looks good.

- image: gardendev/garden-gcloud:${CIRCLE_SHA1}
environment:
<<: *shared-env-config
GARDEN_TASK_CONCURRENCY_LIMIT: "10"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why do we need this here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We don't, it was just in the copy-paste, now removed

- run:
name: Cleanup
command: CIRCLE_BUILD_NUM=$CIRCLE_BUILD_NUM-docker kubectl delete --wait=false $(kubectl get ns -o name | grep testing-$CIRCLE_BUILD_NUM) || true
when: always
cleanup-cluster-registry:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Will this slow down our e2e tests in a meaningful way? Not the cleanup step itself but rather the next run on a "clean" registry. We of course don't delete images in use, so I'm assuming it won't really have an affect, but wanted to confirm.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Not by a lot, but there are other issues with running the test like this. I've instead made it a part of the minikube tests, which is in a more closed environment and has no potential of conflicting with another test.

@@ -374,6 +374,9 @@ jobs:
name: Deploy demo-project with container
# overriding CIRCLE_BUILD_NUM to avoid conflict with other tests
command: CIRCLE_BUILD_NUM=$CIRCLE_BUILD_NUM-docker /garden/garden build --root examples/demo-project --env remote --logger-type basic
- run:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Doesn't this run against the CI cluster?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Indeed. I'll fix.

@@ -4,7 +4,7 @@ name: docker-registry
type: helm
chart: stable/docker-registry
releaseName: garden-docker-registry
version: 1.8.3
version: 1.9.2
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this version already running in our cluster (to make sure the update doesn't break anything)?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It is, yes.

@eysi09
Copy link
Collaborator

eysi09 commented Apr 23, 2020

@edvald, had two outstanding questions :)

@edvald edvald force-pushed the fix-cleanup branch 2 times, most recently from f7dc424 to 4088f98 Compare April 28, 2020 15:48
eysi09
eysi09 previously approved these changes Apr 29, 2020
@eysi09 eysi09 dismissed their stale review April 30, 2020 14:27

Dismissing because of failing e2e tests

@edvald edvald force-pushed the fix-cleanup branch 2 times, most recently from b95644c to 77555d3 Compare May 11, 2020 13:42
@edvald
Copy link
Collaborator Author

edvald commented May 11, 2020

@eysi09 should be good to go now

@eysi09 eysi09 merged commit a2f38ae into master May 12, 2020
@eysi09 eysi09 deleted the fix-cleanup branch May 12, 2020 03:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants