-
Notifications
You must be signed in to change notification settings - Fork 111
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
Run acceptance tests post-merge with large cached state #1282
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dconnolly
added
A-infrastructure
Area: Infrastructure changes
A-devops
Area: Pipelines, CI/CD and Dockerfiles
labels
Nov 12, 2020
… container config to use
Otherwise there's a lot of on-instance commands to do that is just handled by this shortcut.
dconnolly
force-pushed
the
cloudbuild
branch
from
November 12, 2020 16:39
f41e882
to
cb08b93
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
We want to run integration tests that test codepaths particular to post-Sapling activation, which often requires a big cache of state (GBs or so).
Solution
This post-merge pipeline (because of GH Actions secret issues) builds a container image full of the test binaries, spins up a gcloud VM with a new disk mounted at /zebrad-cache inside the test container containing Zebra state synced on mainnet to approximately 1M+ blockheight, and then runs the acceptance tests. If the tests are configured to look in that directory for state, it will be used to 'resume' sync. All test output is streamed to the GH Actions UI for the 'CD' workflow. The VM and the disks are then deleted after the tests are run.
The code in this pull request has:
Unit Tests and Property TestsReview
This will be used by #1229
Related Issues
#745
Follow Up Work
This is using one Dockerfile to do the build we've been doing for a while then copy the test binaries into one image and zebrad binary into another, and then use those in two different parallel 'deploy' jobs. This part alone may be taking more time than we really need for an image that we only 'deploy' for testing, I've learned a lot more about our options and pro/cons about using this infra, I may come back to this and see if literally checking out the code on a large VM, building the tests, running the tests against the drives, and then throwing everything away, saves time at several places.