-
Notifications
You must be signed in to change notification settings - Fork 67
🌱 (ci) add GitHub Action to validate installation #1450
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
Conversation
✅ Deploy Preview for olmv1 ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
f9bc19e
to
43a4410
Compare
43a4410
to
d7083c3
Compare
d7083c3
to
498c88f
Compare
8278af7
to
d4addce
Compare
I don't think this will work on MacOS. On MacOS, when we build a container, we need to specifically cross-compile to GOOS=linux. That's why the |
I think we _can_probably remove the hardcoded GOARCH setting though. |
d8506db
to
6ef6948
Compare
This comment was marked as resolved.
This comment was marked as resolved.
ae0dd26
to
410ebe3
Compare
@camilamacedo86 That container won't be runnable in a cluster because it is |
@@ -0,0 +1,51 @@ | |||
name: Install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think that we need a dedicated action to run the install script. All e2e runs in CI will use the install script so I would expect install script issues to be present in e2e runs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Makefile as it is on 'main' right now works fine for me on Linux. The test you linked to above is failing because it appears it was before you changed the docker-build line to target the ./bin directory rather than ./bin/linux.
I don't have access to a mac but I don't really see how the changes in this PR are really different from how it worked before--it seems to just be changing where we build the binaries from ./bin/linux to ./bin? And it's also effectively removing the functionality of the existing 'go-build-local' target and replacing it with the current 'go-build-linux,' just renaming them and removing the former since you're still setting GOOS=linux.
It is interesting that the existing go-build-local on main isn't directly used anywhere--I'm assuming it's there for cases where somebody wanted to compile locally and would just locally edit the docker-build target to use 'build' for one-off testing. Maybe we should just make another docker-build target that uses -local, i.e. docker-build-local, if that's a workflow we see people needing/wanting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with @everettraven. We are (in theory) automatically generating a manifest and rendering an install script as part of the e2e.
If there are gaps in what happens with the installation during the e2e, let's fix it in the e2e instead of introducing a separate test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@camilamacedo86 Part of running our e2e tests includes doing, more or less, what you are doing here.
If you look at the test-e2e
make target at
Lines 179 to 188 in 6d79092
# When running the e2e suite, you can set the ARTIFACT_PATH variable to the absolute path | |
# of the directory for the operator-controller e2e tests to store the artifacts, which | |
# may be helpful for debugging purposes after a test run. | |
# | |
# for example: ARTIFACT_PATH=/tmp/artifacts make test-e2e | |
.PHONY: test-e2e | |
test-e2e: KIND_CLUSTER_NAME := operator-controller-e2e | |
test-e2e: KUSTOMIZE_BUILD_DIR := config/overlays/e2e | |
test-e2e: GO_BUILD_FLAGS := -cover | |
test-e2e: run image-registry e2e e2e-coverage kind-clean #HELP Run e2e test suite on local kind cluster |
run
target at Lines 279 to 280 in 6d79092
.PHONY: run | |
run: docker-build kind-cluster kind-load kind-deploy #HELP Build the operator-controller then deploy it into a new kind cluster. |
docker-build
, kind-cluster
, kind-load
, and kind-deploy
. The kind-deploy
target at Lines 222 to 226 in 6d79092
.PHONY: kind-deploy | |
kind-deploy: export MANIFEST="./operator-controller.yaml" | |
kind-deploy: manifests $(KUSTOMIZE) #EXHELP Install controller and dependencies onto the kind cluster. | |
$(KUSTOMIZE) build $(KUSTOMIZE_BUILD_DIR) > operator-controller.yaml | |
envsubst '$$CATALOGD_VERSION,$$CERT_MGR_VERSION,$$INSTALL_DEFAULT_CATALOGS,$$MANIFEST' < scripts/install.tpl.sh | bash -s |
Essentially, everything you are doing in this CI action is already done as part of all of our e2e runs in CI.
I'm not quite sure why CI didn't catch the issues you linked, but I also never ended up running into those problems. Is it possible that there may be some difference in tooling versions that resulted in you experiencing those issues?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
docker-build kind-cluster kind-load kind-deploy
I see that is calling so that is true.
Thank you for point out.
Is it possible that there may be some difference in tooling versions that resulted in you experiencing those issues?
Not that is not really possible
if you revert #1429 OR #1411 you will see that the error occurs always.
So probably we move forward besides the e2e failures.
410ebe3
to
1c42056
Compare
This comment was marked as resolved.
This comment was marked as resolved.
1c42056
to
9f93449
Compare
9f93449
to
fc5bbcd
Compare
Closing this one. So, we probably move forward besides the e2e failures. |
We are currently facing issues where the installation process is breaking, and we are unable to detect these failures in CI. This action introduces a validation step to ensure that we can at least install the solution, validating the installation script provided in the Getting Started guide. This is a minimal basic test expected to enhance the developer experience (DX) by reducing user frustration with installation issues.
fc5bbcd
to
1bd3281
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1450 +/- ##
===========================================
- Coverage 74.73% 57.20% -17.53%
===========================================
Files 42 42
Lines 3241 3241
===========================================
- Hits 2422 1854 -568
- Misses 646 1295 +649
+ Partials 173 92 -81
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
scripts/install.tpl.sh
.Motivation:
The error seen in PR #1429 would have been detected with this action in place.