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

chore(operations): Kubernetes test procedure #2487

Merged
merged 14 commits into from
May 7, 2020
Merged

Conversation

MOZGIII
Copy link
Contributor

@MOZGIII MOZGIII commented Apr 28, 2020

This PR outlines the initial test procedure we agreed upon at #2222.

It only includes minikube tests at CI, and it should be very easy to add EKS or GKE one we set them up.

Closes #2223.

@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch 8 times, most recently from bff1c29 to a983d1a Compare April 29, 2020 15:47
@vectordotdev vectordotdev deleted a comment from github-actions bot Apr 29, 2020
@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch 5 times, most recently from 39f2bbb to 1fca1f7 Compare April 30, 2020 16:30
@MOZGIII MOZGIII marked this pull request as ready for review April 30, 2020 16:32
@MOZGIII MOZGIII requested review from a user and binarylogic and removed request for a user April 30, 2020 16:32
@MOZGIII
Copy link
Contributor Author

MOZGIII commented Apr 30, 2020

Should I address sharing the vector binary at this PR, or postpone it to some time later?

@binarylogic
Copy link
Contributor

I assume you mean sharing it across all of our CI jobs? I'd postpone it. I'm also not sure that's possible given that we build Vector with different features for different targets, right?

@MOZGIII
Copy link
Contributor Author

MOZGIII commented Apr 30, 2020

Each of the kubernetes infrastructure tests (1.18, 1.17, etc) currently builds a full release build, then a .deb, and then builds a docker image and pushes it top a repo so that it's accessible to k8s cluster. It's enough to do all those steps once, and reuse the docker image.
Those can be shared not just across the Kubernetes tests, but also among other kinds of tests - for instance - .deb files and also be used at the Test Harness action.

After the docker image is built - we also build the tests (with the kubernetes-specific features) - this is what you mentioned. This part we can't share among non-k8s tests - but across the k8s tests against multiple clusters we can share them too.

Kubernetes tests are designed in a way that we deploy Vector into k8s - this is why we need to build not just the tests, but also the full vector binary (and docker image).

@MOZGIII
Copy link
Contributor Author

MOZGIII commented Apr 30, 2020

Seems like docker push fails:

+ docker push ***:test-1588264400-w2r8937o-alpine
Successfully tagged ***:test-1588264400-w2r8937o-alpine
The push refers to repository [docker.io/***]
4ed201ced5b4: Preparing
7096a04c7355: Preparing
60c64a536e00: Preparing
1b3ee35aacca: Preparing
denied: requested access to the resource is denied

Login step was ok, so the token must not have access to push into timberiodev/vector-ci-builds.

@binarylogic
Copy link
Contributor

I just added that user to the timberiodev org, it should be fixed now.

@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch 2 times, most recently from 841e1ac to 8e3b3e3 Compare April 30, 2020 20:07
@MOZGIII
Copy link
Contributor Author

MOZGIII commented Apr 30, 2020

It's still failing ☹️

@binarylogic
Copy link
Contributor

Docker Hub's permissions are confusing. It should work now 😄 .

@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch 2 times, most recently from 3375240 to 871c86a Compare April 30, 2020 20:22
@MOZGIII
Copy link
Contributor Author

MOZGIII commented May 7, 2020

For some time, I was baffled with how we'd merge this without the Kubernetes implementation present. At the same time, I stumble upon the need to have this functionality at my implementation PR. I think I found the solution.

I'll change the k8s related tests as "allow failed" for now (or do something similar), and we merge this. The downside is people will still see those jobs - but they won't affect build success.
When I start actually implementing the tests - I'll reenable them.

An alternative would be to close this PR and for me to take these changes in my impl PR, but that would needlessly bloat that other PR, complicate the reviews and limit the PR atomicity.

@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch 2 times, most recently from 606dcf4 to 3f19103 Compare May 7, 2020 10:03
@MOZGIII MOZGIII force-pushed the k8s-test-procedure branch from 3f19103 to ef54966 Compare May 7, 2020 10:12
@binarylogic
Copy link
Contributor

I’m fine with that

@MOZGIII MOZGIII merged commit a268196 into master May 7, 2020
@binarylogic binarylogic deleted the k8s-test-procedure branch July 23, 2020 17:33
mengesb pushed a commit to jacobbraaten/vector that referenced this pull request Dec 9, 2020
* Add deployment configs for Kubernetes (YAML files)

Signed-off-by: MOZGIII <[email protected]>

* Add a script to start a local docker registry

Signed-off-by: MOZGIII <[email protected]>

* Add the ability to customize the repo to push docker image to

Signed-off-by: MOZGIII <[email protected]>

* Outline the implementation of the integration-kubernetes GA job

Signed-off-by: MOZGIII <[email protected]>

* Add a kubernetes test running suite

Signed-off-by: MOZGIII <[email protected]>

* Add docker credentials and parameters

Signed-off-by: MOZGIII <[email protected]>

* Allow passing PACKAGE_DEB_USE_CONTAINER explicitly and set it docker at CI

Signed-off-by: MOZGIII <[email protected]>

* Allow vector-config secret as well as configmap

Signed-off-by: MOZGIII <[email protected]>

* Rename vector.toml to managed.toml at vector-daemonset-managed-config ConfigMap

Signed-off-by: MOZGIII <[email protected]>

* Remove the unnecessary comment

Signed-off-by: MOZGIII <[email protected]>

* Scope the global configs by the test namespace

Signed-off-by: MOZGIII <[email protected]>

* Temporarily disable kubernetes tests

Signed-off-by: MOZGIII <[email protected]>

* Do not fail fast the k8s tests

Signed-off-by: MOZGIII <[email protected]>

* Enable slim builds for k8s tests

Signed-off-by: MOZGIII <[email protected]>
Signed-off-by: Brian Menges <[email protected]>
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.

Test all supported Kubernetes minor versions
2 participants